X-Git-Url: http://sjero.net/git/?p=wget;a=blobdiff_plain;f=src%2Fftp-ls.c;h=d1172de520f9ddf1dc64d7854bd7a5879d43b7f6;hp=919b4a602d19f838ca66c501103b578d9f84484a;hb=e2e9b753e47efb8f228b9b14f04f307e4f2489b3;hpb=3e207912bd72a55ee05e127a2f5ee4836099fa24 diff --git a/src/ftp-ls.c b/src/ftp-ls.c index 919b4a60..d1172de5 100644 --- a/src/ftp-ls.c +++ b/src/ftp-ls.c @@ -358,8 +358,8 @@ ftp_parse_unix_ls (const char *file, int ignore_perms) if (error || ignore) { DEBUGP (("Skipping.\n")); - FREE_MAYBE (cur.name); - FREE_MAYBE (cur.linkto); + xfree_null (cur.name); + xfree_null (cur.linkto); xfree (line); continue; } @@ -783,7 +783,7 @@ ftp_parse_ls (const char *file, const enum stype system_type) switch (system_type) { case ST_UNIX: - return ftp_parse_unix_ls (file, FALSE); + return ftp_parse_unix_ls (file, 0); case ST_WINNT: { /* Detect whether the listing is simulating the UNIX format */ @@ -802,16 +802,16 @@ ftp_parse_ls (const char *file, const enum stype system_type) if (c >= '0' && c <='9') return ftp_parse_winnt_ls (file); else - return ftp_parse_unix_ls (file, TRUE); + return ftp_parse_unix_ls (file, 1); } case ST_VMS: return ftp_parse_vms_ls (file); case ST_MACOS: - return ftp_parse_unix_ls (file, TRUE); + return ftp_parse_unix_ls (file, 1); default: logprintf (LOG_NOTQUIET, _("\ Unsupported listing type, trying Unix listing parser.\n")); - return ftp_parse_unix_ls (file, FALSE); + return ftp_parse_unix_ls (file, 0); } } @@ -848,7 +848,7 @@ ftp_index (const char *file, struct url *u, struct fileinfo *f) + (tmpp ? (1 + strlen (tmpp)) : 0) + 2); sprintf (upwd, "%s%s%s@", tmpu, tmpp ? ":" : "", tmpp ? tmpp : ""); xfree (tmpu); - FREE_MAYBE (tmpp); + xfree_null (tmpp); } else upwd = xstrdup ("");