Apart from the patch format, the patch itself looks good.
@Giuseppe: We will require Copyright assignments for Piotr right? This patch may be small, but there are a couple others in the pipeline.
* Wajda, Piotr <pwa...@gmail.net.pl> [160916 22:48]:
Hi,I'd like to start contributing to wget. I've chosen http://savannah.gnu.org/bugs/index.php?46584 for a good start.Please let me know if attached patch is sane. Thanks Piotr
diff --git a/src/ftp.c b/src/ftp.c index 39f20fa..e05d57b 100644 --- a/src/ftp.c +++ b/src/ftp.c @@ -1191,6 +1191,7 @@ Error in server response, closing control connection.\n")); if (opt.spider) { bool exists = false; + bool all_exist = true; struct fileinfo *f; uerr_t _res = ftp_get_listing (u, original_url, con, &f); /* Set the DO_RETR command flag again, because it gets unset when @@ -1206,6 +1207,8 @@ Error in server response, closing control connection.\n")); { exists = true; break; + } else { + all_exist = false; } f = f->next; } @@ -1226,7 +1229,11 @@ Error in server response, closing control connection.\n")); con->csock = -1; fd_close (dtsock); fd_close (local_sock); - return RETRFINISHED; + if(all_exist) { + return RETRFINISHED; + } else { + return FTPNSFOD; + } } if (opt.verbose)
-- Thanking You, Darshit Shah PGP Fingerprint: 7845 120B 07CB D8D6 ECE5 FF2B 2A17 43ED A91A 35B6
signature.asc
Description: PGP signature