Thread View: comp.bugs.sys5
2 messages
2 total messages
Started by The Beach Bum
Thu, 10 Sep 1987 20:16
Strange problem with root directories
Author: The Beach Bum
Date: Thu, 10 Sep 1987 20:16
Date: Thu, 10 Sep 1987 20:16
26 lines
1601 bytes
1601 bytes
Okay, strange new bug (actually, _very_ old bug) occured to me last night while ruminating on the lost+found bug. Here is how you get this bizarre baby to show up. # cd / # /etc/link . a. # cd a. You tell me what is weird about that. So far it exists as far back as my Version 7 system at home. The 5.2 machine at work even has it ... This works in the root directory of any device/partition. The test that causes the bug in namei(sys/nami.c) seems to be NOT testing u.u_dent.d_name[0] for equality with `.', only u.u_dent.d_name[1] is checked! Oh, and the fix I posted earlier for the lost+found bug was wrong ... AFTER comparing u.u_dbuf[i] == u.u_dent.d_name[i], test for u.u_dent.d_name[i] for '\0', not before. (Doing it before causes early termination, so that /. gets found instead of /.profile.) That was yet-another interesting problem ... -- John F. Haugh II HECI Exploration Co. Inc. UUCP: ...!ihnp4!killer!jfh 11910 Greenville Ave, Suite 600 "Don't Have an Oil Well?" Dallas, TX. 75243 " ... Then Buy One!" (214) 231-0993
Re: Strange problem with root directories
Author: Eric Herrin
Date: Fri, 11 Sep 1987 12:40
Date: Fri, 11 Sep 1987 12:40
28 lines
1691 bytes
1691 bytes
>Okay, strange new bug (actually, _very_ old bug) occured to me last night >while ruminating on the lost+found bug. > >Here is how you get this bizarre baby to show up. > ># cd / ># /etc/link . a. ># cd a. > >You tell me what is weird about that. So far it exists as far back as >my Version 7 system at home. The 5.2 machine at work even has it ... >This works in the root directory of any device/partition. The test that >causes the bug in namei(sys/nami.c) seems to be NOT testing u.u_dent.d_name[0] >for equality with `.', only u.u_dent.d_name[1] is checked! > I see nothing weird here.... This works in any directory on my SVR3.1 machine. Maybe it's supposed to crash or something?? Maybe you think it shouldn't work at all? I think it should work, after all, '.' is a directory link, and /etc/link links directories. 'a.' with your example works just fine and is a link to /. /etc/unlink unlinks the link, just like it's supposed to. Could you explain yourself a little better? thanks, eric
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads