]> sjero.net Git - wget/blobdiff - src/ftp.c
Quote some things that needed quoting.
[wget] / src / ftp.c
index d58d67dfe87ff107ab59ed0b9c65c76f34356bb3..8e05a796bb56b864796412075cd39ecc0fd8b71c 100644 (file)
--- a/src/ftp.c
+++ b/src/ftp.c
@@ -945,7 +945,7 @@ Error in server response, closing control connection.\n"));
       if (dtsock < 0)
         {
           logprintf (LOG_NOTQUIET, "accept: %s\n", strerror (errno));
-          return err;
+          return CONERROR;
         }
     }
 
@@ -1371,7 +1371,9 @@ ftp_get_listing (struct url *u, ccon *con, struct fileinfo **f)
   DEBUGP ((_("Using %s as listing tmp file.\n"), quote (lf)));
 
   con->target = xstrdup (lf);
+  xfree (lf);
   err = ftp_loop_internal (u, NULL, con);
+  lf = xstrdup (con->target);
   xfree (con->target);
   con->target = old_target;