[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Diff: null device instead of empty file? [was: svn commit: r17181 - trunk/subversion/libsvn_wc]

From: Julian Foad <julianfoad_at_btopenworld.com>
Date: 2005-11-06 22:50:28 CET

Branko Čibej wrote:
> Erik Huelsmann wrote:
>> I'd like to just call external diffs not working with NUL: broken,
>> though, but should we try to move this change into 1.4RC1 and just
>> see? I'm all for it.
> Hm, yes, an external diff could have problems. I'd also call it broken,
> though -- Cygwin's GNU diff can handle NULL. Unix programs should have
> no problems at all, because for all they care, /dev/null is just another
> file.
> (If someone on Windows uses a diff tool that can't handle a NUL: as a
> file name, they can write a wrapper for it. I don't think we should
> cater to every half-ported utility in the world.)

I don't accept that diff programs should be expected to handle NUL:. The
distinction between devices and files is greater on MS DOS/Windows than on
Unix-like OSes, and it would be reasonable for a diff program to require
regular files.

   $ vim /dev/null

works fine, but would you expect

   C:\> msword NUL:

to do so? And that's not a totally unfair comparison. Diff programs are not
all line-based stdin-reading text stream consumers.

I can join you in wishing that all diff programs would accept NUL:, but I don't
for a moment expect they will.

So that leaves us with just the "users can work around it" argument. No
comment on that at present.

- Julian

To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Nov 6 22:51:32 2005

This is an archived mail posted to the Subversion Dev mailing list.