From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juanma Barranquero Newsgroups: gmane.emacs.devel Subject: Re: emacs server with X11 build on OSX Date: Tue, 3 Aug 2010 04:47:57 +0200 Message-ID: References: <83F33443-0C3F-4F9B-B584-D9301250B8FC@raeburn.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1280803712 27847 80.91.229.12 (3 Aug 2010 02:48:32 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 3 Aug 2010 02:48:32 +0000 (UTC) Cc: 6781@debbugs.gnu.org, Leo , emacs-devel@gnu.org To: Ken Raeburn Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Aug 03 04:48:29 2010 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Og7YH-0005gZ-Op for ged-emacs-devel@m.gmane.org; Tue, 03 Aug 2010 04:48:26 +0200 Original-Received: from localhost ([127.0.0.1]:56688 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Og7YH-0003MH-7j for ged-emacs-devel@m.gmane.org; Mon, 02 Aug 2010 22:48:25 -0400 Original-Received: from [140.186.70.92] (port=58067 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Og7YB-0003MB-MO for emacs-devel@gnu.org; Mon, 02 Aug 2010 22:48:20 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Og7YA-0005kk-FH for emacs-devel@gnu.org; Mon, 02 Aug 2010 22:48:19 -0400 Original-Received: from mail-iw0-f169.google.com ([209.85.214.169]:62776) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Og7YA-0005ka-B7 for emacs-devel@gnu.org; Mon, 02 Aug 2010 22:48:18 -0400 Original-Received: by iwn2 with SMTP id 2so5877386iwn.0 for ; Mon, 02 Aug 2010 19:48:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:received:in-reply-to :references:from:date:message-id:subject:to:cc:content-type :content-transfer-encoding; bh=++npNjE4SVNFxh5LDHYlds1O/XxyDSGfdd/cwDc8grY=; b=G5kZIy/ikBQsZT+kOZ9ZIi0Te3TY4BiXwKmhSjfclCKHTEL04tSIopRkHFOnoMbrZi 5EKolcg0PmmvN5UzFK1am/GpXOhrYKGnpHO+h50ijLxqCXH4O5ucgSZwjr+opc6VGHyo C5d4HJd97v5JcCKCqMvNE5Z7v9Y/nzTVPU6EA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=ERTL92hvSiVIomlom54/8BwdrSzPLUSBSXqqQNGTqo085a7r25EEbaU6GyHJqXZxWO MDu27dah6qq/uWCj5Pv2aHMHsLMaJDOVFHFYZnzCJWhxkAL9DdPD52Hrv7xsdMYKmguW qXuvZNaEX4+h2QsfBNKHTrLq2vpMNKmU4doN8= Original-Received: by 10.231.40.9 with SMTP id i9mr7931048ibe.5.1280803697288; Mon, 02 Aug 2010 19:48:17 -0700 (PDT) Original-Received: by 10.231.162.4 with HTTP; Mon, 2 Aug 2010 19:47:57 -0700 (PDT) In-Reply-To: <83F33443-0C3F-4F9B-B584-D9301250B8FC@raeburn.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:128169 Archived-At: On Tue, Aug 3, 2010 at 04:12, Ken Raeburn wrote: > Using ":host 'local" causes the C code to look up the name "localhost", > which may or may not map to IPv4 and/or IPv6 addresses. =C2=A0(Almost > always an IPv4 address of 127.0.0.1; sometimes IPv6 also, and I've > occasionally seen it mapped to the local ethernet interface's IPv4 > address.) =C2=A0Not specifying the host at all causes a wildcard address = to > be used, which would be reachable from other hosts, whereas > 127.0.0.1 generally is not. [Ah, the wonders of TCP.] I think you're right, because in Leo's examples it works when he specifically sets "127.0.0.1", so it's clear that Emacs isn't selecting that address with "localhost" or 'local. I suppose the Right Thing to do for server.el is to force it to use "127.0.0.1" instead of 'local for the :host argument. =C2=A0 =C2=A0 Juanma =3D=3D=3D modified file 'lisp/server.el' --- lisp/server.el 2010-01-13 08:35:10 +0000 +++ lisp/server.el 2010-08-03 02:44:17 +0000 @@ -561,7 +561,7 @@ ;; The other args depend on the kind of socket used. (if server-use-tcp - (list :family nil + (list :family 'ipv4 :service t - :host (or server-host 'local) + :host (or server-host "127.0.0.1") ;; bug#6781 :plist '(:authenticated nil)) (list :family 'local