Date: Thu, 11 Apr 2002 20:09:42 -0700 From: Gregory Carvalho <GregoryC@stcinc.com> To: FreeBSD-gnats-submit@FreeBSD.org Subject: bin/37013: ls directory name output trailing slash duplcation - PATCH Message-ID: <3CB64FF6.4CC2D434@stcinc.com>
next in thread | raw e-mail | index | archive | help
>Number: 37013 >Category: bin >Synopsis: ls directory name output trailing slash duplcation - PATCH >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu Apr 11 20:20:00 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Gregory Carvalho >Release: FreeBSD 4.5-RELEASE i386 >Organization: Simplified Technology Company >Environment: >Description: ls outputs an aesthetically unpleasant double slash at the conclusion of a direc tory name when the -d and -F options are used and a slash is appended to the dir ectory name in the argument list. >How-To-Repeat: # ls -dF /usr/ /usr// # >Fix: *** ls.slashfix.c Thu Apr 11 19:36:07 2002 --- ls.c Wed Aug 16 12:57:11 2000 *************** *** 570,584 **** continue; } } - /* - * Strip a trailing slash in argv if the options -d and -F - * are in the option list. - */ - if (f_listdir && f_type && - !strcmp(cur->fts_name + cur->fts_namelen - 1, "/")) { - strcpy(cur->fts_name + cur->fts_namelen - 1, "\0"); - cur->fts_namelen -= 1; - } if (cur->fts_namelen > maxlen) maxlen = cur->fts_namelen; if (f_octal || f_octal_escape) { --- 570,575 ---- >Release-Note: >Audit-Trail: >Unformatted: >System: FreeBSD newest.simplifiedtechnology.com 4.5-RELEASE FreeBSD 4.5-RELEASE #0: Mon Apr 1 21:55:35 PST 2002 root@newest.simplifiedtechnology.com:/usr/src/s ys/compile/NEWEST i386 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3CB64FF6.4CC2D434>