GNU bug report logs - #18658
24.3; deformed server-socket-dir

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: emacs; Severity: minor; Reported by: Devon Sean McCullough <Emacs-Hacker2014@HIDDEN>; merged with #24513; dated Tue, 7 Oct 2014 19:59:01 UTC; Maintainer for emacs is bug-gnu-emacs@HIDDEN.
Forcibly Merged 18658 24513. Request was from Glenn Morris <rgm@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 18658 <at> debbugs.gnu.org:


Received: (at 18658) by debbugs.gnu.org; 10 Oct 2014 01:04:01 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Oct 09 21:04:01 2014
Received: from localhost ([127.0.0.1]:39561 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1XcOci-00050k-G9
	for submit <at> debbugs.gnu.org; Thu, 09 Oct 2014 21:04:00 -0400
Received: from fencepost.gnu.org ([208.118.235.10]:53069)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <rgm@HIDDEN>) id 1XcOcg-00050c-2Y
 for 18658 <at> debbugs.gnu.org; Thu, 09 Oct 2014 21:03:58 -0400
Received: from rgm by fencepost.gnu.org with local (Exim 4.71)
 (envelope-from <rgm@HIDDEN>)
 id 1XcOcf-0008DR-84; Thu, 09 Oct 2014 21:03:57 -0400
From: Glenn Morris <rgm@HIDDEN>
To: Devon Sean McCullough <Emacs-Hacker2014@HIDDEN>
Subject: Re: bug#18658: 24.3; deformed server-socket-dir
References: <56FE6C1F-CA39-417F-9C43-CB2351BE2D71@HIDDEN>
X-Spook: Gazprom kilderkin underground espionage AIEWS $400
X-Ran: P\~{Y%FRP5,djixLEN~/r'&F_4E_ZY#|0mug0#Gk&rwZ{(:GQX21.W\\D-#n{}{_[tX0:=
X-Hue: cyan
X-Attribution: GM
Date: Thu, 09 Oct 2014 21:03:57 -0400
In-Reply-To: <56FE6C1F-CA39-417F-9C43-CB2351BE2D71@HIDDEN> (Devon Sean
 McCullough's message of "Tue, 7 Oct 2014 15:57:58 -0400")
Message-ID: <2d4mvcn3b6.fsf@HIDDEN>
User-Agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/)
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Spam-Score: -4.3 (----)
X-Debbugs-Envelope-To: 18658
Cc: 18658 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -4.3 (----)

Devon Sean McCullough wrote:

> Double slashes in server-socket-dir is a bug waiting to happen.

You mean, if someone sets TMPDIR to a value ending in a slash?
POSIX requires (non-leading) multiple / in a filename to be entirely
equivalent to one /, so it it hard to see how this could cause any
problems. Nevertheless expand-file-name does seem a bit cleaner.




Information forwarded to bug-gnu-emacs@HIDDEN:
bug#18658; Package emacs. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 7 Oct 2014 19:58:41 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Tue Oct 07 15:58:41 2014
Received: from localhost ([127.0.0.1]:36914 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.80)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1Xbau9-0002mf-8p
	for submit <at> debbugs.gnu.org; Tue, 07 Oct 2014 15:58:41 -0400
Received: from eggs.gnu.org ([208.118.235.92]:36930)
 by debbugs.gnu.org with esmtp (Exim 4.80)
 (envelope-from <Emacs-Hacker2014@HIDDEN>) id 1Xbau7-0002mX-66
 for submit <at> debbugs.gnu.org; Tue, 07 Oct 2014 15:58:39 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <Emacs-Hacker2014@HIDDEN>) id 1Xbatw-0002IR-UO
 for submit <at> debbugs.gnu.org; Tue, 07 Oct 2014 15:58:39 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: 
X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50 autolearn=disabled
 version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:47299)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <Emacs-Hacker2014@HIDDEN>) id 1Xbatw-0002IN-Rv
 for submit <at> debbugs.gnu.org; Tue, 07 Oct 2014 15:58:28 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:38624)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <Emacs-Hacker2014@HIDDEN>) id 1Xbato-0005Le-KO
 for bug-gnu-emacs@HIDDEN; Tue, 07 Oct 2014 15:58:28 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <Emacs-Hacker2014@HIDDEN>) id 1Xbate-0002BP-Ua
 for bug-gnu-emacs@HIDDEN; Tue, 07 Oct 2014 15:58:20 -0400
Received: from gateway14.websitewelcome.com ([67.18.22.82]:37873)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <Emacs-Hacker2014@HIDDEN>) id 1Xbate-00028a-PI
 for bug-gnu-emacs@HIDDEN; Tue, 07 Oct 2014 15:58:10 -0400
Received: by gateway14.websitewelcome.com (Postfix, from userid 5007)
 id 109BB6530C844; Tue,  7 Oct 2014 14:58:09 -0500 (CDT)
Received: from leaf.websitewelcome.com (leaf.websitewelcome.com
 [192.185.82.99])
 by gateway14.websitewelcome.com (Postfix) with ESMTP id 0191E6530C7A7
 for <bug-gnu-emacs@HIDDEN>; Tue,  7 Oct 2014 14:58:09 -0500 (CDT)
Received: from [24.34.70.237] (port=64242 helo=[192.168.2.138])
 by leaf.websitewelcome.com with esmtpsa (TLSv1:AES128-SHA:128)
 (Exim 4.82) (envelope-from <Emacs-Hacker2014@HIDDEN>)
 id 1Xbatc-00048w-7M
 for bug-gnu-emacs@HIDDEN; Tue, 07 Oct 2014 14:58:08 -0500
From: Devon Sean McCullough <Emacs-Hacker2014@HIDDEN>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Subject: 24.3; deformed server-socket-dir
Message-Id: <56FE6C1F-CA39-417F-9C43-CB2351BE2D71@HIDDEN>
Date: Tue, 7 Oct 2014 15:57:58 -0400
To: bug-gnu-emacs@HIDDEN
Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\))
X-Mailer: Apple Mail (2.1878.6)
X-AntiAbuse: This header was added to track abuse,
 please include it with any abuse report
X-AntiAbuse: Primary Hostname - leaf.websitewelcome.com
X-AntiAbuse: Original Domain - gnu.org
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - jovi.net
X-BWhitelist: no
X-Source-IP: 24.34.70.237
X-Exim-ID: 1Xbatc-00048w-7M
X-Source: 
X-Source-Args: 
X-Source-Dir: 
X-Source-Sender: ([192.168.2.138]) [24.34.70.237]:64242
X-Source-Auth: devon@HIDDEN
X-Email-Count: 1
X-Source-Cap: am92aW5ldDtkZXZvbjtsZWFmLndlYnNpdGV3ZWxjb21lLmNvbQ==
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address
 (bad octet value).
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -5.0 (-----)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <http://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <http://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <http://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -5.0 (-----)

Double slashes in server-socket-dir is a bug waiting to happen.

		Peace
			--Devon

P.S. Fix follows:

--- lisp/server.el.~1~	2014-10-07 13:27:34.000000000 -0400
+++ lisp/server.el	2014-10-07 13:34:03.000000000 -0400
@@ -266,7 +266,10 @@
 ;; does not read the init file.
 (defvar server-socket-dir
   (and (featurep 'make-network-process '(:family local))
-       (format "%s/emacs%d" (or (getenv "TMPDIR") "/tmp") (user-uid)))
+       (expand-file-name (format "emacs%d" 
+				 (user-uid))
+			 (or (getenv "TMPDIR")
+			     "/tmp")))
   "The directory in which to place the server socket.
 If local sockets are not supported, this is nil.")






Acknowledgement sent to Devon Sean McCullough <Emacs-Hacker2014@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs@HIDDEN. Full text available.
Report forwarded to bug-gnu-emacs@HIDDEN:
bug#18658; Package emacs. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Thu, 22 Sep 2016 19:45:01 UTC

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