Never undo the last mount. Make /.. work better.
[rsc] --rw-rw-r-- M 1146153 glenda sys 33663 Dec 30 15:30 sys/src/9/port/chan.c
/n/sourcesdump/2005/1230/plan9/sys/src/9/port/chan.c:412,418 -
/n/sourcesdump/2005/1231/plan9/sys/src/9/port/chan.c:412,418
if(isdotdot(s)){
fixdotdotname(p);
DBG("addelem %s .. => rm %p\n", p->s, p->mtpt[p->mlen-1]);
- if(p->mlen>0 && (c = p->mtpt[--p->mlen])){
+ if(p->mlen>1 && (c = p->mtpt[--p->mlen])){
p->mtpt[p->mlen] = nil;
cclose(c);
}
|