mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

neil_a_wilson
12.06.2007 a3e52f3ef4722b2d7c4541259239fb4501d0d374
Fix a bug in the ldif-diff tool that creates the potential that an entry
contained in both the source and target LDIF files will be included in the
output as an "add" record (potentially even if it also appears earlier in the
output as a "modify" record).

OpenDS Issue Number: 1227
1 files modified
6 ■■■■■ changed files
opendj-sdk/opends/src/server/org/opends/server/tools/LDIFDiff.java 6 ●●●●● patch | view | raw | blame | history
opendj-sdk/opends/src/server/org/opends/server/tools/LDIFDiff.java
@@ -22,7 +22,7 @@
 * CDDL HEADER END
 *
 *
 *      Portions Copyright 2006 Sun Microsystems, Inc.
 *      Portions Copyright 2006-2007 Sun Microsystems, Inc.
 */
package org.opends.server.tools;
@@ -462,7 +462,7 @@
          {
            // The target entry should be before the source entry, which means
            // that the target entry has been added.
            writeAdd(writer,targetEntry);
            writeAdd(writer, targetEntry);
            differenceFound = true;
            if (targetIterator.hasNext())
            {
@@ -520,6 +520,8 @@
                sourceEntry = sourceMap.get(sourceDN);
                writeDelete(writer, sourceEntry);
              }
              break;
            }
          }
        }