mercurial/narrowspec.py
changeset 39539 8d8e61df8259
parent 39531 0d572769046a
child 39544 10a8472f6662
--- a/mercurial/narrowspec.py	Mon Sep 10 22:34:19 2018 +0900
+++ b/mercurial/narrowspec.py	Tue Sep 11 15:28:41 2018 -0700
@@ -164,9 +164,15 @@
     if profiles:
         raise error.Abort(_("including other spec files using '%include' is not"
                             " supported in narrowspec"))
+
+    validatepatterns(includepats)
+    validatepatterns(excludepats)
+
     return includepats, excludepats
 
 def save(repo, includepats, excludepats):
+    validatepatterns(includepats)
+    validatepatterns(excludepats)
     spec = format(includepats, excludepats)
     repo.svfs.write(FILENAME, spec)