diff -r b2a36e9b9ccc -r f0d55e1b4855 mercurial/patch.py --- a/mercurial/patch.py Sun Mar 24 16:56:25 2013 -0700 +++ b/mercurial/patch.py Mon Mar 04 22:34:11 2013 +0000 @@ -1756,6 +1756,8 @@ else: header.append('deleted file mode %s\n' % gitmode[man1.flags(f)]) + if util.binary(to): + dodiff = 'binary' elif not to or util.binary(to): # regular diffs cannot represent empty file deletion losedatafn(f)