bin/89410: commit references a PR
dfilter service
dfilter at FreeBSD.ORG
Wed Mar 3 16:10:08 UTC 2010
The following reply was made to PR bin/89410; it has been noted by GNATS.
From: dfilter at FreeBSD.ORG (dfilter service)
To: bug-followup at FreeBSD.org
Cc:
Subject: Re: bin/89410: commit references a PR
Date: Wed, 3 Mar 2010 16:06:52 +0000 (UTC)
Author: jh
Date: Wed Mar 3 16:06:43 2010
New Revision: 204637
URL: http://svn.freebsd.org/changeset/base/204637
Log:
MFC r204276:
Fix expansion of \W in prompt strings when the working directory is "/".
The prompt string was truncated after \W when the working directory was "/".
PR: bin/89410
Modified:
stable/8/bin/sh/parser.c
Directory Properties:
stable/8/bin/sh/ (props changed)
Modified: stable/8/bin/sh/parser.c
==============================================================================
--- stable/8/bin/sh/parser.c Wed Mar 3 15:43:26 2010 (r204636)
+++ stable/8/bin/sh/parser.c Wed Mar 3 16:06:43 2010 (r204637)
@@ -1631,7 +1631,7 @@ getprompt(void *unused __unused)
case 'w':
ps[i] = '\0';
getcwd(&ps[i], PROMPTLEN - i);
- if (*fmt == 'W') {
+ if (*fmt == 'W' && ps[i + 1] != '\0') {
/* Final path component only. */
trim = 1;
for (j = i; ps[j] != '\0'; j++)
_______________________________________________
svn-src-all at freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscribe at freebsd.org"
More information about the freebsd-bugs
mailing list