]> git.eshelyaron.com Git - emacs.git/commitdiff
(command-line-1): Kill emacs if the last frame is deleted while
authorChong Yidong <cyd@stupidchicken.com>
Sun, 5 Nov 2006 17:35:08 +0000 (17:35 +0000)
committerChong Yidong <cyd@stupidchicken.com>
Sun, 5 Nov 2006 17:35:08 +0000 (17:35 +0000)
evaluating the command-line arguments.

lisp/startup.el

index 91491ac25e266e5d9d3ff779dccae14fbfe41b1a..8268ac534003d81991754b9aa22a3377be5fd99d 100644 (file)
@@ -1893,7 +1893,12 @@ With a prefix argument, any user input hides the splash screen."
                          (setq line 0)
                          (unless (< column 1)
                            (move-to-column (1- column)))
-                         (setq column 0))))))))
+                         (setq column 0))))))
+         ;; In unusual circumstances, the execution of Lisp code due
+         ;; to command-line options can cause the last visible frame
+         ;; to be deleted.  In this case, kill emacs to avoid an
+         ;; abort later.
+         (unless (frame-live-p (selected-frame)) (kill-emacs nil))))
 
       ;; If 3 or more files visited, and not all visible,
       ;; show user what they all are.  But leave the last one current.