all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Two Tramp issues
@ 2002-08-02 20:29 Lars Hansen
  2002-08-03  8:51 ` Kai Großjohann
  0 siblings, 1 reply; 2+ messages in thread
From: Lars Hansen @ 2002-08-02 20:29 UTC (permalink / raw)
  Cc: bug-gnu-emacs

Hi

1. Bug:
   It seems that current buffer is changed to be the Tramp buffer
   when Tramp handles `make-directory'.

2. Question:
   Is it correct that previosly a function such as eg. `make-directory'
   was not caught by the "file name magic" when `make-directory' was
   called with a relative file name and default-directory was a Tramp
   file name -- but that this is now corrected ?
   It so, is this change documented ?

I use Emacs 20 and 21 and `tramp-version' is
"$Id: tramp.el,v 2.95 2002/04/10 17:16:25 kaig Exp $"

Lars

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Two Tramp issues
  2002-08-02 20:29 Two Tramp issues Lars Hansen
@ 2002-08-03  8:51 ` Kai Großjohann
  0 siblings, 0 replies; 2+ messages in thread
From: Kai Großjohann @ 2002-08-03  8:51 UTC (permalink / raw)
  Cc: bug-gnu-emacs

"Lars Hansen" <larsh@math.ku.dk> writes:

> 1. Bug:
>    It seems that current buffer is changed to be the Tramp buffer
>    when Tramp handles `make-directory'.

Right.  Please try this patch.

--- tramp.el.~2.162.~	Wed Jul 31 17:23:43 2002
+++ tramp.el	Sat Aug  3 10:48:04 2002
@@ -2407,13 +2407,14 @@
   (with-parsed-tramp-file-name dir nil
     (when (tramp-ange-ftp-file-name-p multi-method method)
       (tramp-invoke-ange-ftp 'make-directory dir parents))
-    (tramp-barf-unless-okay
-     multi-method method user host
-     (format " %s %s"
-	     (if parents "mkdir -p" "mkdir")
-	     (tramp-shell-quote-argument path))
-     nil 'file-error
-     "Couldn't make directory %s" dir)))
+    (save-excursion
+      (tramp-barf-unless-okay
+       multi-method method user host
+       (format " %s %s"
+	       (if parents "mkdir -p" "mkdir")
+	       (tramp-shell-quote-argument path))
+       nil 'file-error
+       "Couldn't make directory %s" dir))))
 
 ;; CCC error checking?
 (defun tramp-handle-delete-directory (directory)


> 2. Question:
>    Is it correct that previosly a function such as eg. `make-directory'
>    was not caught by the "file name magic" when `make-directory' was
>    called with a relative file name and default-directory was a Tramp
>    file name -- but that this is now corrected ?
>    It so, is this change documented ?

Well, this is possible.  I recently did this change:

2002-07-26  Kai Großjohann  <Kai.Grossjohann@CS.Uni-Dortmund.DE>

	* tramp.el (tramp-coding-commands): New variable.
	(tramp-find-inline-encoding): New function.
	(tramp-handle-make-directory, tramp-handle-delete-directory)
	(tramp-handle-delete-file): Do expand-file-name on arg.

This is from the ChangeLog in Tramp.  Maybe this detail got lost in
the ChangeLog in Emacs.

kai
-- 
A large number of young women don't trust men with beards.  (BFBS Radio)

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-08-03  8:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-08-02 20:29 Two Tramp issues Lars Hansen
2002-08-03  8:51 ` Kai Großjohann

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.