Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.1 exptools 1/6/84; site ihu1h.UUCP
Path: utzoo!watmath!clyde!burl!mgnetp!ihnp4!ihu1h!steffen
From: steffen@ihu1h.UUCP (Joe Steffen)
Newsgroups: net.unix-wizards
Subject: What is the root inode number in BSD 4.1 and 4.2?
Message-ID: <280@ihu1h.UUCP>
Date: Fri, 3-Aug-84 17:11:26 EDT
Article-I.D.: ihu1h.280
Posted: Fri Aug  3 17:11:26 1984
Date-Received: Sat, 4-Aug-84 02:27:57 EDT
Organization: AT&T Bell Labs, Naperville, IL
Lines: 12

In System V you can test to see if the current directory is root by 

	if (stat(".", &status) == 0 && status.st_ino == ROOTINO)
	
where ROOTINO defined in sys/params.h as 2.  This header file in BSD 4.2
does not have ROOTINO.  Is 2 the correct value in BSD, is it something
else, or do I have to stat("/", ...) to get the value?  I want to avoid the
latter if possible.
-- 


#	Joe Steffen, AT&T Bell Labs, Naperville, IL, (312) 979-5381