Fix directory handling, & UNC paths, & shortnames
Windows visual diff and merge for files and directories
Brought to you by:
christianlist,
grimmdp
OpenDlg., resource files, Merge.dsp, (new) paths.
Logged In: YES
user_id=60964
One new string resource: IDS_ERROR_INCOMPARABLE
Two new source files (paths.cpp and paths.h).
(So if you just add them to the dsp yourself, you don't need
the dsp in the patch zip).
Logged In: YES
user_id=631874
Is '=' correct inside while or should it be '=='?
// now walk down each directory
// using CFileFind to get its long name
while ((end = _tcschr(ptr, '\\')))
Compiler gives warning, so if it is intentional, please add
comment?
Regards,
Kimmo
Logged In: YES
user_id=631874
Forgot to mention that lines are from paths_GetLongPath()
Logged In: YES
user_id=60964
(Yep, intentional.)
Strange; I didn't notice a warning (although, as we're using
the same dsp file, that probably was my error in not
noticing it).
I thought the extra parentheses were enough to shut off that
warning; that is show we always suppressed it before. But
anyway, another, even clearer but longer, workaround to
suppress it is
while (0 != (end = _tcschr(ptr, '\\')))
Logged In: YES
user_id=631874
With this patch, WinMerge fails to open paths like:
\\server\dir1\dir2\dir3\dir4\dir5\
If I remove trailing slash, then opening succeeds...
And, paths like:
c:\dir1\dir2\dir3\
can be compared too.
Regards,
Kimmo
Logged In: YES
user_id=60964
Fixed both the warning, and the UNC not working with
trailing slash bug, and also now updated with new merge.cpp
and merge.dsp changes (esc code & multimon include,
respectively). Uploading new zip.
Note that this doesn't preserve trailing slashes across the
persistence. This doesn't make it fail, but it would be
nicer if directories were always marked with trailing slash
in the editboxes. But, this would take a bit of work, as we
have to mark them that way before saving -- when loading you
can't (AFAIK) test a UNC path to see if it is really a
directory the way you can a local path (for local path you
can just use CFile::GetStatus and check the directory bit).
Updated version, fix warning, bug, and integrate new cvs changes
Logged In: YES
user_id=631874
I have tested this patch for a couple of days without other
problems. So please checkin this.
Logged In: YES
user_id=60964
Checked in.
Logged In: YES
user_id=631874
I submitted bug "699382 - Cannot compare files from
commandline". Caused by this patch.
My mistake too, since I commented this works for me.
Duh. I thought there is no differences for command line
parameter paths and open dialog paths...
I mention in bug that relative path does not seem to work
from commandline. That didn't work before patch, so it's RFE.
Logged In: YES
user_id=60964
Well, this is applied, so I'm closing it.
It so happens that it also is buggy, as reported by Kimmo,
but now that is a bug against the cvs itself...