Function: tramp-error
tramp-error is a byte-compiled function defined in tramp.el.gz.
Signature
(tramp-error VEC-OR-PROC SIGNAL FMT-STRING &rest ARGUMENTS)
Documentation
Emit an error.
VEC-OR-PROC identifies the connection to use, SIGNAL is the
signal identifier to be raised, remaining arguments passed to
tramp-message. Finally, signal SIGNAL is raised with
FMT-STRING and ARGUMENTS.
Source Code
;; Defined in /usr/src/emacs/lisp/net/tramp.el.gz
(defun tramp-error (vec-or-proc signal fmt-string &rest arguments)
"Emit an error.
VEC-OR-PROC identifies the connection to use, SIGNAL is the
signal identifier to be raised, remaining arguments passed to
`tramp-message'. Finally, signal SIGNAL is raised with
FMT-STRING and ARGUMENTS."
(let (signal-hook-function)
(tramp-backtrace vec-or-proc)
(unless arguments
;; FMT-STRING could be just a file name, as in
;; `file-already-exists' errors. It could contain the ?\%
;; character, as in smb domain spec.
(setq arguments (list fmt-string)
fmt-string "%s"))
(when vec-or-proc
(tramp-message
vec-or-proc 1 "%s"
(error-message-string
(list signal
(get signal 'error-message)
(apply #'format-message fmt-string arguments)))))
(signal signal (list (substring-no-properties
(apply #'format-message fmt-string arguments))))))