[issue1728] extdiff: Create empty tempdir instead of passing NUL

173 mercurial-bugs at selenic.com
Wed Jul 8 04:04:02 CDT 2009


New submission from 173 <0703mercurial.20.thg at spamgourmet.com>:

If there's only one file added, extdiff passes nul to the diff program:

==========
C:\>hg version
Mercurial Distributed SCM (version 1.3)

Copyright (C) 2005-2009 Matt Mackall <mpm at selenic.com> and others
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

C:\>hg init repo
C:\>cd repo
C:\repo>echo foobar >1
C:\repo>hg add
adding 1
C:\repo>echo echo %*% >C:\echo.bat
C:\repo>hg extdiff -p C:\echo.bat
c:\dokume~1\tsg\lokale~1\temp\extdiff.82ceuz>echo "nul" "C:\repo\1"
"nul" "C:\repo\1"
==========

Perhaps this is an elegant method for some (unix) diff programs, but it confuses
others (windows). IMHO it would be better if an empty tempdir would be created -
actually the same what is done by now if you add a second file:

==========
C:\repo>echo foobar >2
C:\repo>hg add
adding 2
C:\repo>hg extdiff -p C:\echo.bat
c:\dokume~1\tsg\lokale~1\temp\extdiff.itdhmo>echo "repo.000000000000" "repo"
"repo.000000000000" "repo"
==========

----------
messages: 9925
nosy: 173
priority: wish
status: unread
title: extdiff: Create empty tempdir instead of passing NUL
topic: extdiff, windows

____________________________________________________
Mercurial issue tracker <mercurial-bugs at selenic.com>
<http://mercurial.selenic.com/bts/issue1728>
____________________________________________________



More information about the Mercurial-devel mailing list