bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: unfilled path in getsockname() for unix sockets


From: Samuel Thibault
Subject: Re: unfilled path in getsockname() for unix sockets
Date: Sun, 4 Dec 2011 23:04:57 +0100
User-agent: Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30)

Pino Toscano, le Sun 04 Dec 2011 16:45:20 +0100, a écrit :
> Alle domenica 4 dicembre 2011, Samuel Thibault ha scritto:
> > Pino Toscano, le Sun 04 Dec 2011 13:14:52 +0100, a écrit :
> > > while debugging, I apparently stumbled upon a bug of getsockname()
> > > for a bound unix socket, as also the attached test program shows:
> > > sun_path is left unfilled, as also the comment of
> > > S_socket_whatis_address() in hurd/pflocal/pf.c would suggest.
> > 
> > Which is a design choice, apparently: only glibc's bind.c knows about
> > the socket path.
> 
> Hmm :-/ And there's really no way to get it later?

With the current design, I don't think it can: it's like an opened file,
you can't know where you are coming from, since it may be hardlinked in
several places for instance.

Samuel



reply via email to

[Prev in Thread] Current Thread [Next in Thread]