changeset 106508:8c836ea59444

* net/tramp.el (tramp-handle-insert-directory): Suppress error messages.
author Michael Albinus <michael.albinus@gmx.de>
date Wed, 09 Dec 2009 10:23:00 +0000
parents 9506b5eee678
children b5f38c883bf8
files lisp/ChangeLog lisp/net/tramp.el
diffstat 2 files changed, 12 insertions(+), 8 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Wed Dec 09 10:10:18 2009 +0000
+++ b/lisp/ChangeLog	Wed Dec 09 10:23:00 2009 +0000
@@ -1,3 +1,7 @@
+2009-12-09  Michael Albinus  <michael.albinus@gmx.de>
+
+	* net/tramp.el (tramp-handle-insert-directory): Suppress error messages.
+
 2009-12-09  Dan Nicolaescu  <dann@ics.uci.edu>
 
 	Fix short log parsing and fontification.
--- a/lisp/net/tramp.el	Wed Dec 09 10:10:18 2009 +0000
+++ b/lisp/net/tramp.el	Wed Dec 09 10:23:00 2009 +0000
@@ -4077,7 +4077,7 @@
       (if full-directory-p
 	  (tramp-send-command
 	   v
-	   (format "%s %s %s"
+	   (format "%s %s %s 2>/dev/null"
 		   (tramp-get-ls-command v)
 		   switches
 		   (if wildcard
@@ -4126,13 +4126,13 @@
 		    (end (+ beg (read (current-buffer)))))
 		(if (memq (char-after end) '(?\n ?\ ))
 		    ;; End is followed by \n or by " -> ".
-		    (put-text-property start end 'dired-filename t)))))
-	  ;; Remove trailing lines.
-	  (goto-char (tramp-compat-line-beginning-position))
-	  (while (looking-at "//")
-	    (forward-line 1)
-	    (delete-region (match-beginning 0) (point)))))
-      (goto-char (point-max)))))
+		    (put-text-property start end 'dired-filename t))))))
+	;; Remove trailing lines.
+	(goto-char (tramp-compat-line-beginning-position))
+	(while (looking-at "//")
+	  (forward-line 1)
+	  (delete-region (match-beginning 0) (point)))
+	(goto-char (point-max))))))
 
 (defun tramp-handle-unhandled-file-name-directory (filename)
   "Like `unhandled-file-name-directory' for Tramp files."