]> asedeno.scripts.mit.edu Git - PuTTY.git/blobdiff - psftp.c
When looking for a local username on Windows, if we can get hold of the
[PuTTY.git] / psftp.c
diff --git a/psftp.c b/psftp.c
index fe01b1a9b500f3edf16a770df9fc524f9358d5ee..65d52c3bd86f830e0db4fe702a1c0bda997b45f0 100644 (file)
--- a/psftp.c
+++ b/psftp.c
@@ -16,6 +16,8 @@
 #include "sftp.h"
 #include "int64.h"
 
+const char *const appname = "PSFTP";
+
 /*
  * Since SFTP is a request-response oriented protocol, it requires
  * no buffer management: when we send data, we stop and wait for an
@@ -2516,7 +2518,8 @@ int from_backend(void *frontend, int is_stderr, const char *data, int datalen)
      */
     if (is_stderr) {
        if (len > 0)
-           fwrite(data, 1, len, stderr);
+           if (fwrite(data, 1, len, stderr) < len)
+               /* oh well */;
        return 0;
     }