From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Joakim =?UTF-8?Q?H=C3=A5rsman?= Newsgroups: gmane.emacs.bugs Subject: bug#6136: Emerge doesn't handle file names with spaces on MS Windows Date: Fri, 7 May 2010 21:19:36 +0200 Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: dough.gmane.org 1273329846 29012 80.91.229.12 (8 May 2010 14:44:06 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 8 May 2010 14:44:06 +0000 (UTC) To: 6136@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat May 08 16:44:04 2010 connect(): No such file or directory Return-path: Envelope-to: geb-bug-gnu-emacs@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 1OAlG8-0005gT-FV for geb-bug-gnu-emacs@m.gmane.org; Sat, 08 May 2010 16:44:04 +0200 Original-Received: from localhost ([127.0.0.1]:54052 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OAlG7-0002Id-NE for geb-bug-gnu-emacs@m.gmane.org; Sat, 08 May 2010 10:44:03 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1OATim-00023u-2d for bug-gnu-emacs@gnu.org; Fri, 07 May 2010 16:00:28 -0400 Original-Received: from [140.186.70.92] (port=34529 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OATfb-0005LH-IT for bug-gnu-emacs@gnu.org; Fri, 07 May 2010 16:00:26 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OATeh-0004z1-P4 for bug-gnu-emacs@gnu.org; Fri, 07 May 2010 15:56:17 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:53256) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OATeh-0004yv-LJ for bug-gnu-emacs@gnu.org; Fri, 07 May 2010 15:56:15 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1OATFL-0001ft-6j; Fri, 07 May 2010 15:30:03 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Joakim =?UTF-8?Q?H=C3=A5rsman?= Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 07 May 2010 19:30:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 6136 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.12732605606411 (code B ref -1); Fri, 07 May 2010 19:30:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 7 May 2010 19:29:20 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OATEe-0001fM-49 for submit@debbugs.gnu.org; Fri, 07 May 2010 15:29:20 -0400 Original-Received: from mail.gnu.org ([199.232.76.166] helo=mx10.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OAT5M-0001al-6G for submit@debbugs.gnu.org; Fri, 07 May 2010 15:19:44 -0400 Original-Received: from lists.gnu.org ([199.232.76.165]:52638) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1OAT5K-0005V5-99 for submit@debbugs.gnu.org; Fri, 07 May 2010 15:19:42 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1OAT5J-0000ag-G3 for bug-gnu-emacs@gnu.org; Fri, 07 May 2010 15:19:41 -0400 Original-Received: from [140.186.70.92] (port=33999 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OAT5H-0000ZR-VY for bug-gnu-emacs@gnu.org; Fri, 07 May 2010 15:19:40 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OAT5G-0006xt-NS for bug-gnu-emacs@gnu.org; Fri, 07 May 2010 15:19:39 -0400 Original-Received: from mail-fx0-f41.google.com ([209.85.161.41]:51156) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OAT5G-0006xX-I8 for bug-gnu-emacs@gnu.org; Fri, 07 May 2010 15:19:38 -0400 Original-Received: by fxm7 with SMTP id 7so254527fxm.0 for ; Fri, 07 May 2010 12:19:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=ZhWhxj4C6hdpDjUcX+pxcmdT1X9V8aeXN9/5GKD7xRc=; b=YYlEUJ9ct3hP2wNRtHSlBE5quNnCthJm3DFUQmeihLZE0p6HIp0ecR9dUfdkrFVkw5 CtuzCCax+eOeW72pfwxWW4BGM/+mbJwz2nzto1fOx+k/I+hKI/TVFROU0inlfOIcbOlb 7N59q1pibfbN8N8c+L+qPC/uk7ZZ38WHuQBr0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=jlUBjqp0KNQbUcAuoxPXOZgKhxgqGkD8LjcYPzUWVqmv6ixz1BDRZVOFJZhaNteO7h slj8P1hCJNAw/XrRZ6W6DbfMwrnN6p+Qdk9XYdBD44+E/UIGBQTj9OASDC7AEcrQuo6m heDLh+peh9SffeuigXsRVr4400gBsZOXUywng= Original-Received: by 10.103.37.28 with SMTP id p28mr195113muj.86.1273259976258; Fri, 07 May 2010 12:19:36 -0700 (PDT) Original-Received: by 10.103.218.1 with HTTP; Fri, 7 May 2010 12:19:36 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Mailman-Approved-At: Fri, 07 May 2010 15:29:19 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Fri, 07 May 2010 15:30:03 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Mailman-Approved-At: Sat, 08 May 2010 10:29:24 -0400 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:36793 Archived-At: If any of the file names supplied to Emerge (e.g to emerge-files-with-ancestor) has spaces in in its path and Emacs is running on MS Windows, the merge fails. The problem is the way Emerge passes the file names to diff, it tries to escape spaces (and other metchars) with backslashes, but that doesn't work on MS Windows since the backslash is a path separator there. If I change the definition of emerge-protect-metachars to the following it works: (defun emerge-protect-metachars (s) (if (member system-type '(windows-nt ms-dos)) (emerge-protect-metachars-win s) (emerge-protect-metachars-nix s))) (defun emerge-protect-metachars-nix (s) (let ((limit 0)) (while (string-match emerge-metachars s limit) (setq s (concat (substring s 0 (match-beginning 0)) "\\" (substring s (match-beginning 0)))) (setq limit (1+ (match-end 0))))) s) (defun emerge-protect-metachars-win (s) (concat "\"" s "\"")) Here's some output which might be useful: GNU Emacs 23.1.1 (i386-mingw-nt5.1.2600) of 2009-07-30 on SOFT-MJASON