diff lib/sshv2.c @ 520:e67a52327b24

2004-7-27 Brian Masney <masneyb@gftp.org> * lib/gftp.h lib/local.c lib/protocols.c lib/sshv2.c - changed declaration of gftp_stat_filename() so that the mode of the filename is returned as a parameter instead of the function return value. The mode_t type is unsigned and the error codes could not be reported properly
author masneyb
date Wed, 28 Jul 2004 02:19:00 +0000
parents c3edcd3e9db9
children 739afd9df73c
line wrap: on
line diff
--- a/lib/sshv2.c	Wed Jul 28 01:58:28 2004 +0000
+++ b/lib/sshv2.c	Wed Jul 28 02:19:00 2004 +0000
@@ -1689,8 +1689,9 @@
 }
 
 
-static mode_t
-sshv2_stat_filename (gftp_request * request, const char *filename)
+static int
+sshv2_stat_filename (gftp_request * request, const char *filename,
+                     mode_t * mode)
 {
   gftp_file fle;
   mode_t ret;
@@ -1700,10 +1701,10 @@
   if (ret < 0)
     return (ret);
 
-  ret = fle.st_mode;
+  *mode = fle.st_mode;
   gftp_file_destroy (&fle);
 
-  return (ret);
+  return (0);
 }