emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r103911: * net/tramp-sh.el (tramp-sh-


From: Michael Albinus
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r103911: * net/tramp-sh.el (tramp-sh-handle-file-attributes): Handle the
Date: Thu, 14 Apr 2011 20:58:45 +0200
User-agent: Bazaar (2.3.1)

------------------------------------------------------------
revno: 103911
committer: Michael Albinus <address@hidden>
branch nick: trunk
timestamp: Thu 2011-04-14 20:58:45 +0200
message:
  * net/tramp-sh.el (tramp-sh-handle-file-attributes): Handle the
  case when the scripts fail.  Use `tramp-do-file-attributes-with-ls'
  then.
  (tramp-do-copy-or-rename-file-out-of-band): Do not check any
  longer, whether`executable-find' is bound.
  
  * net/tramp-smb.el (tramp-smb-handle-copy-file): Fix docstring.
modified:
  lisp/ChangeLog
  lisp/net/tramp-sh.el
  lisp/net/tramp-smb.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2011-04-14 00:16:11 +0000
+++ b/lisp/ChangeLog    2011-04-14 18:58:45 +0000
@@ -1,3 +1,13 @@
+2011-04-14  Michael Albinus  <address@hidden>
+
+       * net/tramp-sh.el (tramp-sh-handle-file-attributes): Handle the
+       case when the scripts fail.  Use `tramp-do-file-attributes-with-ls'
+       then.
+       (tramp-do-copy-or-rename-file-out-of-band): Do not check any
+       longer, whether`executable-find' is bound.
+
+       * net/tramp-smb.el (tramp-smb-handle-copy-file): Fix docstring.
+
 2011-04-14  Stefan Monnier  <address@hidden>
 
        * minibuffer.el (completion-in-region-mode-predicate)

=== modified file 'lisp/net/tramp-sh.el'
--- a/lisp/net/tramp-sh.el      2011-03-12 15:19:29 +0000
+++ b/lisp/net/tramp-sh.el      2011-04-14 18:58:45 +0000
@@ -1145,13 +1145,15 @@
        (save-excursion
          (tramp-convert-file-attributes
           v
-          (cond
-           ((tramp-get-remote-stat v)
-            (tramp-do-file-attributes-with-stat v localname id-format))
-           ((tramp-get-remote-perl v)
-            (tramp-do-file-attributes-with-perl v localname id-format))
-           (t
-            (tramp-do-file-attributes-with-ls v localname id-format)))))))))
+          (or
+           (cond
+            ((tramp-get-remote-stat v)
+             (tramp-do-file-attributes-with-stat v localname id-format))
+            ((tramp-get-remote-perl v)
+             (tramp-do-file-attributes-with-perl v localname id-format))
+            (t nil))
+           ;; The scripts could fail, for example with huge file size.
+           (tramp-do-file-attributes-with-ls v localname id-format))))))))
 
 (defun tramp-do-file-attributes-with-ls (vec localname &optional id-format)
   "Implement `file-attributes' for Tramp files using the ls(1) command."
@@ -2296,10 +2298,9 @@
                (tramp-get-method-parameter method 'tramp-copy-env))))
 
        ;; Check for program.
-       (when (and (fboundp 'executable-find)
-                  (not (let ((default-directory
-                               (tramp-compat-temporary-file-directory)))
-                         (executable-find copy-program))))
+       (unless (let ((default-directory
+                       (tramp-compat-temporary-file-directory)))
+                 (executable-find copy-program))
          (tramp-error
           v 'file-error "Cannot find copy program: %s" copy-program))
 

=== modified file 'lisp/net/tramp-smb.el'
--- a/lisp/net/tramp-smb.el     2011-02-05 10:03:29 +0000
+++ b/lisp/net/tramp-smb.el     2011-04-14 18:58:45 +0000
@@ -339,7 +339,7 @@
            preserve-uid-gid preserve-selinux-context)
   "Like `copy-file' for Tramp files.
 KEEP-DATE is not handled in case NEWNAME resides on an SMB server.
-PRESERVE-UID-GID is completely ignored."
+PRESERVE-UID-GID and PRESERVE-SELINUX-CONTEXT are completely ignored."
   (setq filename (expand-file-name filename)
        newname (expand-file-name newname))
   (with-progress-reporter


reply via email to

[Prev in Thread] Current Thread [Next in Thread]