🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.bugs.sys5
Article #592

Strange problem with root directories

#592
From: The Beach Bum
Date: Thu, 10 Sep 1987 20:16
26 lines
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
Technical Details
Message-ID: <1515@killer.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!husc6!cmcl2!rutgers!mtune!codas!killer!jfh

Show Full Headers
Complete Article Headers
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: arc1-ca.pugleaf.net!utzoo!mnetor!uunet!husc6!cmcl2!rutgers!mtune!codas!killer!jfh
From: jfh@killer.UUCP (The Beach Bum)
Newsgroups: comp.bugs.sys5,comp.unix.wizards
Subject: Strange problem with root directories
Message-ID: <1515@killer.UUCP>
Date: Thu, 10-Sep-87 16:16:46 EDT
Article-I.D.: killer.1515
Posted: Thu Sep 10 16:16:46 1987
Date-Received: Sat, 12-Sep-87 11:22:17 EDT
Organization: Big "D" Home for Wayward Hackers
Lines: 26
Keywords: bizarre root directory bug