OSDN Git Service

PATCH: [ 2929005 ] Quickcompare and EOL
authorKimmo Varis <kimmov@gmail.com>
Mon, 11 Jan 2010 19:48:26 +0000 (19:48 +0000)
committerKimmo Varis <kimmov@gmail.com>
Mon, 11 Jan 2010 19:48:26 +0000 (19:48 +0000)
 Fixes bug #2210403
 Submitted by Matthias Mayer

Docs/Users/ChangeLog.txt
Src/CompareEngines/ByteComparator.cpp

index f7abf75..e9d1970 100644 (file)
@@ -16,6 +16,7 @@ WinMerge 2.3.11
   Bugfix: File panes become unaligned when last line didn't have
     an EOL byte (#2922517)
   Bugfix: Automatic rescanning was not disabled everywhere (r7086,r7089)
+  Bugfix: Quick contents compare didn't ignore EOL byte differences (#2929005)
 
 WinMerge 2.13.10 2009-12-21 (r7051)
   Visual Studio project files upgraded to VS2005 format (r7045)
index d64cb69..9646305 100644 (file)
@@ -180,6 +180,12 @@ ByteComparator::COMP_RESULT ByteComparator::CompareBuffers(
        // cycle through buffer data performing actual comparison
        while (true)
        {
+               // we are at the end on one side?
+               if ((ptr0 == end0) || (ptr1 == end1))
+               {
+                       goto need_more;
+               }
+
                if (m_ignore_all_space)
                {
                        // Skip over any whitespace on either side