Re: [PATCH] Canonicalize socket directory, not full path

2012-11-24 Thread Romain Francoise
Thomas Adam writes: > Wasn't this already looked in to? Thanks, I wasn't aware of this previous discussion... > Certainly there's a patch attached to that thread from Nicholas. It never made it into CVS, so the bug is still there. --

Re: [PATCH] Canonicalize socket directory, not full path

2012-11-24 Thread Thomas Adam
On 24 November 2012 18:13, Romain Francoise wrote: > When tmux starts for the very first time we call realpath() on a socket > path that doesn't exist yet, the server hasn't started so the socket > hasn't been created. On Linux at least, this fails with ENOENT and leaves > the path unchanged, so i

[PATCH] Canonicalize socket directory, not full path

2012-11-24 Thread Romain Francoise
When tmux starts for the very first time we call realpath() on a socket path that doesn't exist yet, the server hasn't started so the socket hasn't been created. On Linux at least, this fails with ENOENT and leaves the path unchanged, so it can contain a double slash (e.g. /tmp//tmux-uid/label). T