]> git.eshelyaron.com Git - emacs.git/commitdiff
* lisp/progmodes/grep.el (grep-process-setup): Don't check code for 1
authorJuri Linkov <juri@jurta.org>
Sun, 18 Sep 2011 20:20:08 +0000 (23:20 +0300)
committerJuri Linkov <juri@jurta.org>
Sun, 18 Sep 2011 20:20:08 +0000 (23:20 +0300)
because `zgrep' returns 1 for successful matches.

Fixes: debbugs:9226
lisp/ChangeLog
lisp/progmodes/grep.el

index b820fc24d51366a81fe43d70bdc454dfdc99bcda..c8e9faa3a2b9c5a5fda366ec89f2a2fe9a4f6619 100644 (file)
@@ -1,3 +1,8 @@
+2011-09-18  Juri Linkov  <juri@jurta.org>
+
+       * progmodes/grep.el (grep-process-setup): Don't check code for 1
+       because `zgrep' returns 1 for successful matches (bug#9226).
+
 2011-09-18  Juri Linkov  <juri@jurta.org>
 
        * info.el (Info-extract-menu-node-name): Check the second match
index 000243b05df29bc1bb6f820fbf800621c0f01aa5..2c68a29dd0094920c87d576e7dde109519ba5729 100644 (file)
@@ -476,7 +476,7 @@ Set up `compilation-exit-message-function' and run `grep-setup-hook'."
             ;; so the buffer is still unmodified if there is no output.
             (cond ((and (zerop code) (buffer-modified-p))
                    '("finished (matches found)\n" . "matched"))
-                  ((or (= code 1) (not (buffer-modified-p)))
+                  ((not (buffer-modified-p))
                    '("finished with no matches found\n" . "no match"))
                   (t
                    (cons msg code)))