aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1996-01-25 20:14:38 +0000
committerRichard M. Stallman1996-01-25 20:14:38 +0000
commitb20d527dec0b09923a947976bb818a554b2ca0ab (patch)
tree28b1f655246e8d5b6864b88d0dde4583d2d2c0fd
parent8f44c55eccca3558a6a304e9d5af0d50556597fd (diff)
downloademacs-b20d527dec0b09923a947976bb818a554b2ca0ab.tar.gz
emacs-b20d527dec0b09923a947976bb818a554b2ca0ab.zip
(browse-url-netscape): Check for call-process returning a string.
-rw-r--r--lisp/browse-url.el29
1 files changed, 16 insertions, 13 deletions
diff --git a/lisp/browse-url.el b/lisp/browse-url.el
index ae4cc5d4d19..cb440398b54 100644
--- a/lisp/browse-url.el
+++ b/lisp/browse-url.el
@@ -486,19 +486,22 @@ used instead of browse-url-new-window-p."
486 (interactive (append (browse-url-interactive-arg "Netscape URL: ") 486 (interactive (append (browse-url-interactive-arg "Netscape URL: ")
487 (list (not (eq (null browse-url-new-window-p) 487 (list (not (eq (null browse-url-new-window-p)
488 (null current-prefix-arg)))))) 488 (null current-prefix-arg))))))
489 (or (zerop 489 (let ((res
490 (apply 'call-process "netscape" nil nil nil 490 (apply 'call-process "netscape" nil nil nil
491 (append browse-url-netscape-arguments 491 (append browse-url-netscape-arguments
492 (if new-window '("-noraise")) 492 (if new-window '("-noraise"))
493 (list "-remote" 493 (list "-remote"
494 (concat "openURL(" url 494 (concat "openURL(" url
495 (if new-window ",new-window") 495 (if new-window ",new-window")
496 ")"))))) 496 ")"))))
497 (progn ; Netscape not running - start it 497 ))
498 (message "Starting Netscape...") 498 (if (stringp res)
499 (apply 'start-process "netscape" nil "netscape" 499 (error "netscape got signal: %s" res)
500 (append browse-url-netscape-arguments (list url))) 500 (or (zerop res)
501 (message "Starting Netscape...done")))) 501 (progn ; Netscape not running - start it
502 (message "Starting Netscape...")
503 (apply 'start-process "netscape" nil "netscape"
504 (append browse-url-netscape-arguments (list url))))))))
502 505
503(defun browse-url-netscape-reload () 506(defun browse-url-netscape-reload ()
504 "Ask Netscape to reload its current document." 507 "Ask Netscape to reload its current document."