unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: don@donarmstrong.com (Emacs bug Tracking System)
To: Chong Yidong <cyd@stupidchicken.com>
Subject: bug#767: marked as done (23.0.60; compilation-start gives bad  default-directory)
Date: Sun, 7 Sep 2008 12:20:03 -0700	[thread overview]
Message-ID: <handler.767.D767.12208147253696.ackdone@emacsbugs.donarmstrong.com> (raw)
In-Reply-To: 48B00B00.1050305@gmail.com

[-- Attachment #1: Type: text/plain, Size: 867 bytes --]


Your message dated Sun, 07 Sep 2008 15:14:50 -0400
with message-id <87prnfu5sl.fsf@cyd.mit.edu>
and subject line Re: 23.0.60; compilation-start gives bad default-directory
has caused the Emacs bug report #767,
regarding 23.0.60; compilation-start gives bad default-directory
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact don@donarmstrong.com
immediately.)


-- 
767: http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=767
Emacs Bug Tracking System
Contact don@donarmstrong.com with problems

[-- Attachment #2: Type: message/rfc822, Size: 4455 bytes --]

[-- Attachment #2.1.1: Type: text/plain, Size: 925 bytes --]

If on w32 default-directory is something like c:\top\sub then the
subprocess started by compilation-start will get pwd=c:\top.

This can be cured by the attached patch for this special case, but it is
only a demonstration of the problem, not the right fix for this problem.

The attached patch only does

  (let ((default-directory (file-name-as-directory default-directory))

just before calling `start-file-process-shell-command'.

A slightly better fix would probably be to add the same thing in
`start-file-process', but it seems to me that this should handled at the
C level to catch all cases. I do not know where to do that but it must
be done somewhere before make_process in start-process.


In GNU Emacs 23.0.60.1 (i386-mingw-nt5.1.2600)
 of 2008-08-10
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (3.4) --no-opt --cflags
-Ic:/g/include -fno-crossjumping'

[-- Attachment #2.1.2: compile-start-default-directory.diff --]
[-- Type: text/plain, Size: 675 bytes --]

? compile-start-default-directory.diff
Index: compile.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/progmodes/compile.el,v
retrieving revision 1.476
diff -b -u -r1.476 compile.el
--- compile.el	13 Jun 2008 16:22:16 -0000	1.476
+++ compile.el	23 Aug 2008 12:49:59 -0000
@@ -1246,7 +1246,8 @@
 	    (funcall compilation-process-setup-function))
 	(compilation-set-window-height outwin)
 	;; Start the compilation.
-	(let ((proc
+	(let* ((default-directory (file-name-as-directory default-directory))
+               (proc
 	       (if (eq mode t)
 		   ;; comint uses `start-file-process'.
 		   (get-buffer-process

[-- Attachment #3: Type: message/rfc822, Size: 1003 bytes --]

From: Chong Yidong <cyd@stupidchicken.com>
To: "Lennart Borgman \(gmail\)" <lennart.borgman@gmail.com>
Cc: 767-done@emacsbugs.donarmstrong.com
Subject: Re: 23.0.60; compilation-start gives bad default-directory
Date: Sun, 07 Sep 2008 15:14:50 -0400
Message-ID: <87prnfu5sl.fsf@cyd.mit.edu>

I've checked in the fix.


  reply	other threads:[~2008-09-07 19:20 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <87prnfu5sl.fsf@cyd.mit.edu>
2008-08-23 13:05 ` bug#767: 23.0.60; compilation-start gives bad default-directory Lennart Borgman (gmail)
2008-09-07 19:20   ` Emacs bug Tracking System [this message]
2008-09-07 19:34   ` Stefan Monnier
2008-09-07 19:40     ` Lennart Borgman (gmail)
2008-09-07 19:59       ` Stefan Monnier
2008-09-07 20:04         ` Lennart Borgman (gmail)
2008-09-07 20:38           ` Stefan Monnier
2008-09-07 20:59             ` Lennart Borgman (gmail)
2008-09-07 21:19     ` Eli Zaretskii
2008-09-07 23:48       ` Lennart Borgman (gmail)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=handler.767.D767.12208147253696.ackdone@emacsbugs.donarmstrong.com \
    --to=don@donarmstrong.com \
    --cc=cyd@stupidchicken.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).