From 2fe9c5d4607d4c280e5f7350befa086d8e4fe990 Mon Sep 17 00:00:00 2001
From: neil_a_wilson <neil_a_wilson@localhost>
Date: Mon, 12 Feb 2007 19:06:54 +0000
Subject: [PATCH] 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/src/server/org/opends/server/tools/LDIFDiff.java |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/opends/src/server/org/opends/server/tools/LDIFDiff.java b/opends/src/server/org/opends/server/tools/LDIFDiff.java
index 25562f8..e7f6f04 100644
--- a/opends/src/server/org/opends/server/tools/LDIFDiff.java
+++ b/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;
             }
           }
         }

--
Gitblit v1.10.0