aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Albinus2014-06-02 15:51:35 +0200
committerMichael Albinus2014-06-02 15:51:35 +0200
commit1924ea8c2970a51f30e75ff370e61313e35b3a64 (patch)
treec854d1985afe66ca1facdaf4b637167fd81b2629
parent9acc8834b3ed183407c56be62df9ad9456cfbd3d (diff)
downloademacs-1924ea8c2970a51f30e75ff370e61313e35b3a64.tar.gz
emacs-1924ea8c2970a51f30e75ff370e61313e35b3a64.zip
* net/tramp.el (with-tramp-progress-reporter, tramp-call-process):
Add traces.
-rw-r--r--lisp/ChangeLog3
-rw-r--r--lisp/net/tramp.el21
2 files changed, 15 insertions, 9 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 54ecd84e08b..10de84b3c41 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,6 +1,7 @@
12014-06-02 Michael Albinus <michael.albinus@gmx.de> 12014-06-02 Michael Albinus <michael.albinus@gmx.de>
2 2
3 * net/tramp.el (tramp-call-process): Add traces. 3 * net/tramp.el (with-tramp-progress-reporter, tramp-call-process):
4 Add traces.
4 5
52014-06-02 Wilson Snyder <wsnyder@wsnyder.org> 62014-06-02 Wilson Snyder <wsnyder@wsnyder.org>
6 7
diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el
index 5164c4b32bb..9be0cbe10a9 100644
--- a/lisp/net/tramp.el
+++ b/lisp/net/tramp.el
@@ -1676,7 +1676,8 @@ without a visible progress reporter."
1676 (prog1 (progn ,@body) (setq cookie "done")) 1676 (prog1 (progn ,@body) (setq cookie "done"))
1677 ;; Stop progress reporter. 1677 ;; Stop progress reporter.
1678 (if tm (tramp-compat-funcall 'cancel-timer tm)) 1678 (if tm (tramp-compat-funcall 'cancel-timer tm))
1679 (tramp-message ,vec ,level "%s...%s" ,message cookie))))) 1679 (tramp-message ,vec ,level "%s...%s" ,message cookie)
1680 (when (string-equal "failed" cookie) (tramp-backtrace ,vec))))))
1680 1681
1681(tramp-compat-font-lock-add-keywords 1682(tramp-compat-font-lock-add-keywords
1682 'emacs-lisp-mode '("\\<with-tramp-progress-reporter\\>")) 1683 'emacs-lisp-mode '("\\<with-tramp-progress-reporter\\>"))
@@ -4128,13 +4129,17 @@ Furthermore, traces are written with verbosity of 6."
4128 (tramp-message 4129 (tramp-message
4129 v 6 "`%s %s' %s %s" 4130 v 6 "`%s %s' %s %s"
4130 program (mapconcat 'identity args " ") infile destination) 4131 program (mapconcat 'identity args " ") infile destination)
4131 (with-temp-buffer 4132 (condition-case err
4132 (setq result 4133 (with-temp-buffer
4133 (apply 4134 (setq result
4134 'call-process program infile (or destination t) display args)) 4135 (apply
4135 (with-current-buffer 4136 'call-process program infile (or destination t) display args))
4136 (if (bufferp destination) destination (current-buffer)) 4137 (with-current-buffer
4137 (tramp-message v 6 "%d\n%s" result (buffer-string)))) 4138 (if (bufferp destination) destination (current-buffer))
4139 (tramp-message v 6 "%d\n%s" result (buffer-string))))
4140 (error
4141 (setq result 1)
4142 (tramp-message v 6 "%d\n%s" result (error-message-string err))))
4138 result)) 4143 result))
4139 4144
4140;;;###tramp-autoload 4145;;;###tramp-autoload