bin/101316: /bin/sh pwd bug after cd into restricted directory
Michael MacInnis
michaelmacinnis at rogers.com
Fri Aug 18 15:50:21 UTC 2006
The following reply was made to PR bin/101316; it has been noted by GNATS.
From: "Michael MacInnis" <michaelmacinnis at rogers.com>
To: <bug-followup at FreeBSD.org>,
<aragon at phat.za.net>
Cc:
Subject: Re: bin/101316: /bin/sh pwd bug after cd into restricted directory
Date: Fri, 18 Aug 2006 11:42:20 -0400
Adding a call to updatepwd(NULL) in cd.c seems to fix the problem:
@@ -202,6 +202,7 @@
INTOFF;
if (updatepwd(badstat ? NULL : dest) < 0 || chdir(curdir) < 0) {
+ updatepwd(NULL);
INTON;
return (-1);
}
This may also address PR bin/64990.
Michael MacInnis.
More information about the freebsd-bugs
mailing list