hgext/rebase.py
changeset 36394 4bc983568016
parent 36299 238646784294
child 36400 7b86aa31b004
--- a/hgext/rebase.py	Sat Feb 24 16:06:21 2018 +0530
+++ b/hgext/rebase.py	Sat Feb 24 16:07:45 2018 +0530
@@ -1440,7 +1440,7 @@
 def isagitpatch(repo, patchname):
     'Return true if the given patch is in git format'
     mqpatch = os.path.join(repo.mq.path, patchname)
-    for line in patch.linereader(file(mqpatch, 'rb')):
+    for line in patch.linereader(open(mqpatch, 'rb')):
         if line.startswith('diff --git'):
             return True
     return False