diff -r 027264e720aa -r 0145f9afb0e7 mercurial/patch.py --- a/mercurial/patch.py Sat Dec 29 01:14:45 2007 +0100 +++ b/mercurial/patch.py Sat Dec 29 19:49:48 2007 +0100 @@ -818,7 +818,7 @@ fname = (afile in bfile) and afile or bfile elif gooda: fname = afile - + if not fname: if not nullb: fname = (afile in bfile) and afile or bfile @@ -826,7 +826,7 @@ fname = afile else: raise PatchError(_("undefined source and destination files")) - + return fname, missing class linereader: @@ -1029,7 +1029,7 @@ for gp in gitpatches: if gp.op in ('COPY', 'RENAME'): copyfile(gp.oldpath, gp.path) - changed[gp.path] = (gp.op, gp) + changed[gp.path] = (gp.op, gp) else: raise util.Abort(_('unsupported parser state: %s') % state)