From: sgunderson Date: Fri, 20 Jul 2001 14:49:25 +0000 (+0000) Subject: Fixed a bug where option parsing would begin parse the file name as options. X-Git-Url: https://git.sesse.net/?p=betaftpd;a=commitdiff_plain;h=3db72e3acbb4e75acf041ada3a0630bce128b8be Fixed a bug where option parsing would begin parse the file name as options. --- diff --git a/cmds.c b/cmds.c index cd8cfbc..e25fd62 100644 --- a/cmds.c +++ b/cmds.c @@ -1845,7 +1845,7 @@ int prepare_for_listing(struct conn * const c, char ** const ptr, case 'F': lo->classify = 1; break; - case ' ': + case '\0': fptr = optr + 1; *(optr--) = 0; break; @@ -1856,7 +1856,7 @@ int prepare_for_listing(struct conn * const c, char ** const ptr, } else { fptr = c->recv_buf; } - + /* then we chdir to the dir in fptr (if any) */ tmp = fptr ? strrchr(fptr, '/') : NULL; if (tmp != NULL) {