Re: open problem

Joseph H. Buehler (
17 Jan 1998 14:21:37 -0500

Jason Watts <> writes:

> Hi!
> If a dir is nothing but a file with dir entries, with its own
> inode etc., why wasn't an open system call implemented for directories?
> How exectly does the opendir libr. routine work?

There was once a time when people did use open() to read directories.
Then BSD changed what was in directories (14 character filenames were
a major bummer), and broke a lot of code that knew what was in
directories. So now everyone uses opendir() and doesn't worry about
what is in directories.

Joe Buehler