diff options
| author | Nick Roberts | 2007-12-28 08:09:57 +0000 |
|---|---|---|
| committer | Nick Roberts | 2007-12-28 08:09:57 +0000 |
| commit | a50d124451e48606aef655c0cde38b4cbf139988 (patch) | |
| tree | d4cf83c5ba3ba3979e424ca881caa8388bc72735 | |
| parent | dacc50beea01618f0ebd030e3d99e2368a9638ce (diff) | |
| download | emacs-a50d124451e48606aef655c0cde38b4cbf139988.tar.gz emacs-a50d124451e48606aef655c0cde38b4cbf139988.zip | |
(thumbs-call-convert): Use call-process directly
with thumbs-conversion-program instead of through shell-file-name
for better error reporting when program is missing.
| -rw-r--r-- | lisp/thumbs.el | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/lisp/thumbs.el b/lisp/thumbs.el index 9d8b289cbe9..395145fd53b 100644 --- a/lisp/thumbs.el +++ b/lisp/thumbs.el | |||
| @@ -248,15 +248,12 @@ ARG any arguments to the ACTION command, | |||
| 248 | OUTPUT-FORMAT is the file format to output (default is jpeg), | 248 | OUTPUT-FORMAT is the file format to output (default is jpeg), |
| 249 | ACTION-PREFIX is the symbol to place before the ACTION command | 249 | ACTION-PREFIX is the symbol to place before the ACTION command |
| 250 | (defaults to '-' but can sometimes be '+')." | 250 | (defaults to '-' but can sometimes be '+')." |
| 251 | (let ((command (format "%s %s%s %s \"%s\" \"%s:%s\"" | 251 | (call-process thumbs-conversion-program nil nil nil |
| 252 | thumbs-conversion-program | 252 | (or action-prefix "-") |
| 253 | (or action-prefix "-") | 253 | action |
| 254 | action | 254 | (or arg "") |
| 255 | (or arg "") | 255 | filein |
| 256 | filein | 256 | (format "%s:%s" (or output-format "jpeg") fileout))) |
| 257 | (or output-format "jpeg") | ||
| 258 | fileout))) | ||
| 259 | (call-process shell-file-name nil nil nil shell-command-switch command))) | ||
| 260 | 257 | ||
| 261 | (defun thumbs-new-image-size (s increment) | 258 | (defun thumbs-new-image-size (s increment) |
| 262 | "New image (a cons of width x height)." | 259 | "New image (a cons of width x height)." |