diff -r 82f6193ff2bc -r 76b07a5c064b mercurial/transaction.py --- a/mercurial/transaction.py Fri Jun 03 00:44:20 2016 +0900 +++ b/mercurial/transaction.py Fri Jun 03 00:44:20 2016 +0900 @@ -310,7 +310,8 @@ self.registertmp(name, location=location) else: self.addbackup(name, location=location) - files.append(vfs(name, 'w', atomictemp=True)) + files.append(vfs(name, 'w', atomictemp=True, + checkambig=not suffix)) genfunc(*files) finally: for f in files: