GNU bug report logs - #20999
24.4; Inconsistent UID vs USER resolution between emacsclient and emacs daemon

Previous Next

Package: emacs;

Reported by: Mike Alexander <mikealexander1860 <at> gmail.com>

Date: Tue, 7 Jul 2015 05:00:03 UTC

Severity: normal

Tags: moreinfo, wontfix

Found in version 24.4

Done: Glenn Morris <rgm <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #14 received at 20999 <at> debbugs.gnu.org (full text, mbox):

From: Wolfgang Jenkner <wjenkner <at> inode.at>
To: Mike Alexander <mikealexander1860 <at> gmail.com>
Cc: 20999 <at> debbugs.gnu.org
Subject: Re: bug#20999: 24.4;
 Inconsistent UID vs USER resolution between emacsclient and emacs
 daemon
Date: Wed, 08 Jul 2015 20:03:20 +0200
On Tue, Jul 07 2015, Mike Alexander wrote:

> I get a
> connection refused from the command "emacsclient -c -s $EMACS_DAEMON_NAME"
> after starting and confirming the daemon is running via the command "emacs
> --daemon=$EMACS_DAEMON_NAME".  

Since connect() is a syscall you could run emacsclient under strace to
easily find out with which arguments it is called.  In my case (using
truss under FreeBSD) I see the following syscalls leading up to the
connect() call

socket(PF_LOCAL,SOCK_STREAM,0)                  = 3 (0x3)
geteuid()                                       = 1002 (0x3ea)
mmap(0x0,4194304,PROT_READ|PROT_WRITE,MAP_PRIVATE|MAP_ANON,-1,0x0) = 34380709888 (0x801400000)
stat("/tmp/emacs1002/foobar",{ mode=srwx------ ,inode=23,size=0,blksize=4096 }) = 0 (0x0)
geteuid()                                       = 1002 (0x3ea)
madvise(0x801406000,0x1000,0x5,0xaaaaaaaaaaaaaaab,0x801400030,0x800de29e0) = 0 (0x0)
connect(3,{ AF_UNIX "/tmp/emacs1002/foobar" },23) = 0 (0x0)





This bug report was last modified 8 years and 245 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.