This is the mail archive of the
libc-hacker@sourceware.cygnus.com
mailing list for the glibc project.
Re: ttyname() and linux+devfs
Matthias Urlichs wrote:
>
> In dist.glibc, article <909753268.29893@noris.de>,
> Kenneth Johansson <erakeon@kieray1.p.y.ki.era.ericsson.se> writes:
> >
> > That could explain why I dont get the thing to run I dont have a /proc. What
> > would happen if i dont have /proc.
>
> You lose, ttyname() fails. The same happens now if you dynamically create
> the device files for your tty in /tmp.
>
> That's not a normal case under Linux. Startup environments or embedded
> minimal environments don't need ttyname(), IMHO.
What about chroot jails though? These are far from uncommon in Real
Life(tm). To have to mount /proc within a chroot jail exposes gross things
like /proc/kcore, which rather defeats the point! (NB yes, you can mount the
proc filesystem multiple times).
> Or alternately we could fall back on the old method.
That would be good IMHO. The test is obviously trivial.
Jifl
--
Cygnus Solutions, 35 Cambridge Place, Cambridge, UK. Tel: +44 (1223) 728762
"Women marry hoping their husbands will change, men||Home e-mail: jifl @
marry hoping their wives never do. Both are rare." || jifvik.demon.co.uk
Help fight spam! http://spam.abuse.net/ These opinions are all my own fault