emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] externals/dicom 5f87368c2a 6/8: Raise errors


From: ELPA Syncer
Subject: [elpa] externals/dicom 5f87368c2a 6/8: Raise errors
Date: Fri, 20 Dec 2024 12:58:00 -0500 (EST)

branch: externals/dicom
commit 5f87368c2af2ec7325099e023fae8e44b19674b3
Author: Daniel Mendler <mail@daniel-mendler.de>
Commit: Daniel Mendler <mail@daniel-mendler.de>

    Raise errors
---
 dicom.el | 11 +++++++++--
 1 file changed, 9 insertions(+), 2 deletions(-)

diff --git a/dicom.el b/dicom.el
index bce6a80b4d..4489232430 100644
--- a/dicom.el
+++ b/dicom.el
@@ -146,7 +146,10 @@
 (defun dicom--read (file)
   "Read DICOM FILE and return list of items."
   (let ((dom (with-temp-buffer
-               (call-process "dcm2xml" nil t nil "--quiet" "--charset-assume" 
"latin-1" "--convert-to-utf8" file)
+               (unless (eq 0 (call-process "dcm2xml" nil t nil
+                                           "--quiet" "--charset-assume"
+                                           "latin-1" "--convert-to-utf8" file))
+                 (error "dcm2xml failed"))
                (libxml-parse-xml-region)))
         (items nil))
     (dolist (item (append (and (not (string-suffix-p "DICOMDIR" file))
@@ -255,7 +258,11 @@ If REUSE is non-nil, reuse image buffer."
     (cond
      ((file-exists-p dst)
       (message "Playing %s…" dicom--file)
-      (call-process-shell-command (format "(mpv --loop %s) & disown" 
(shell-quote-argument dst)) nil 0))
+      (unless (eq 0 (call-process-shell-command
+                     (format "(mpv --loop %s) & disown"
+                             (shell-quote-argument dst))
+                     nil 0))
+        (error "mpv failed")))
      (dicom--proc
       (message "Conversion in progress…"))
      (t



reply via email to

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