emacs-devel
[Top][All Lists]
Advanced

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

Re: error in server-running-p on M$


From: Ulrich Mueller
Subject: Re: error in server-running-p on M$
Date: Sat, 22 Nov 2008 15:13:10 +0100

>>>>> On Sat, 22 Nov 2008, Eli Zaretskii wrote:

>> Index: lisp/server.el
>> ===================================================================
>> RCS file: /sources/emacs/emacs/lisp/server.el,v
>> retrieving revision 1.173
>> diff -u -2 -r1.173 server.el
>> --- lisp/server.el   5 Nov 2008 21:16:17 -0000       1.173
>> +++ lisp/server.el   7 Nov 2008 15:37:36 -0000
>> @@ -537,5 +537,15 @@
>> (unless name (setq name server-name))
>> (condition-case nil
>> -      (progn
>> +      (if server-use-tcp
>> +      (with-temp-buffer
>> +        (insert-file-contents-literally
>> +         (expand-file-name server-name server-auth-dir))
>> +        (and (looking-at "127\.0\.0\.1:[0-9]+ \\([0-9]+\\)")
>> +             (let ((case-fold-search t)
>> +                   (proc (assq 'comm
>> +                               (system-process-attributes
>> +                                (string-to-number (match-string 1))))))
>> +               (and proc
>> +                    (string-match-p "emacs" (cdr proc))))))
>> (delete-process
>> (make-network-process
>> 

> Does anyone see any problems with this change?  If not, I suggest to
> install it.

Shouldn't it try to actually connect to the socket (in the
server-use-tcp case), to find out if the server is functional?
That would also be consistent with the behaviour for local sockets.

Ulrich




reply via email to

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