mercurial/commands.py
changeset 614 6bff574d639f
parent 613 5374955ec5b1
child 615 ad2999fad721
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -586,7 +586,7 @@ def import_(ui, repo, patch1, *patches, 
 
         text = ""
         for l in file(pf):
-            if l[:4] == "--- ": break
+            if l.startswith("--- ") or l.startswith("diff -r"): break
             text += l
 
         # parse values that exist when importing the result of an hg export