Re: Mysterious file descriptor behavior
From: Alex Fraser (me_at_privacy.net)
Date: 10/28/05
- Next message: Matt Garman: "Re: XShape example(s)?"
- Previous message: joe_at_invalid.address: "Re: Mysterious file descriptor behavior"
- In reply to: joe_at_invalid.address: "Re: Mysterious file descriptor behavior"
- Next in thread: joe_at_invalid.address: "Re: Mysterious file descriptor behavior"
- Reply: joe_at_invalid.address: "Re: Mysterious file descriptor behavior"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Fri, 28 Oct 2005 20:50:52 +0100
<joe@invalid.address> wrote in message
news:m38xwd5xwv.fsf@invalid.address...
> "Alex Fraser" <me@privacy.net> writes:
> > <joe@invalid.address> wrote in message
> > news:m3hdb163sj.fsf@invalid.address...
> > > 50295@web.de writes:
> > [snip]
> > > > -bash-3.00$ ls -l /proc/$$/fd
> > > > total 4
> > > > lrwx------ 1 myname mygroup 64 Oct 28 16:34 0 -> /dev/pts/0
> > > > lrwx------ 1 myname mygroup 64 Oct 28 16:34 1 -> /dev/pts/0
> > > > lrwx------ 1 myname mygroup 64 Oct 28 16:34 2 -> /dev/pts/0
> > > > lrwx------ 1 myname mygroup 64 Oct 28 16:39 255 -> /dev/pts/0
> > [snip]
> > > Descriptor 255 isn't standard, it depends on the system as to what
> > > it means and whether it's there (it's not there on solaris for
> > > example).
> >
> > Note that the command is listing the descriptors open in the shell.
>
> Sorry, you lost me there. Are you saying it is standard somehow?
No, I'm saying it need not conform to any standard because it is the shell's
business what fds it has open.
(I haven't looked at the source, but would guess the above is done so the
shell can write to the tty/whatever after fds 0-2 have possibly been
replaced with pipe ends/files/whatever.)
Alex
- Next message: Matt Garman: "Re: XShape example(s)?"
- Previous message: joe_at_invalid.address: "Re: Mysterious file descriptor behavior"
- In reply to: joe_at_invalid.address: "Re: Mysterious file descriptor behavior"
- Next in thread: joe_at_invalid.address: "Re: Mysterious file descriptor behavior"
- Reply: joe_at_invalid.address: "Re: Mysterious file descriptor behavior"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|