leoliu pushed a commit to branch master
in repository elpa.

commit 754f45e413415028ff92c0fc53312f1de92c7452
Author: Leo Liu <sdl....@gmail.com>
Date:   Wed Mar 19 10:18:35 2014 +0800

    Fix thinko in "Don't display buffer if ggtags-navigation-mode is exited"
    
    of commit a4ba72b12124d125e49db217603c6542fbc98a5b.
    
    Fix ggtags-handle-single-match not to display the window if
    interrupted.
---
 ggtags.el |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/ggtags.el b/ggtags.el
index 789982a..b686eda 100644
--- a/ggtags.el
+++ b/ggtags.el
@@ -1133,7 +1133,7 @@ Use \\[jump-to-register] to restore the search session."
     (replace-match ""))
   (cl-incf ggtags-global-output-lines
            (count-lines compilation-filter-start (point)))
-  (when (and (> ggtags-global-output-lines 5) (not ggtags-navigation-mode))
+  (when (and (> ggtags-global-output-lines 5) ggtags-navigation-mode)
     (ggtags-global--display-buffer))
   (make-local-variable 'ggtags-global-large-output)
   (when (> ggtags-global-output-lines ggtags-global-large-output)
@@ -1142,8 +1142,8 @@ Use \\[jump-to-register] to restore the search session."
       (message "Output %d lines (Type `C-c C-k' to cancel)"
                ggtags-global-output-lines))))
 
-(defun ggtags-handle-single-match (buf _how)
-  (if (not (zerop ggtags-global-exit-status))
+(defun ggtags-handle-single-match (buf how)
+  (if (string-prefix-p "exited abnormally" how)
       ;; If exit abnormally display the buffer for inspection.
       (ggtags-global--display-buffer)
     (when (and ggtags-auto-jump-to-first-match

Reply via email to