diff mercurial/revset.py @ 12321:11db6fa2961e

merge with stable
author Martin Geisler <mg@aragost.com>
date Mon, 20 Sep 2010 15:42:58 +0200
parents 6f833fc3ccab 40c40c6f20b8
children b913232d13c1
line wrap: on
line diff
--- a/mercurial/revset.py	Fri Sep 17 12:45:13 2010 -0500
+++ b/mercurial/revset.py	Mon Sep 20 15:42:58 2010 +0200
@@ -276,7 +276,10 @@
     return l
 
 def grep(repo, subset, x):
-    gr = re.compile(getstring(x, _("grep wants a string")))
+    try:
+        gr = re.compile(getstring(x, _("grep wants a string")))
+    except re.error, e:
+        raise error.ParseError(_('invalid match pattern: %s') % e)
     l = []
     for r in subset:
         c = repo[r]