From d2638c88e3e5228597bf95487a0cf0c82f9e5bf5 Mon Sep 17 00:00:00 2001
From: dugan <dugan@localhost>
Date: Thu, 29 Mar 2007 18:09:52 +0000
Subject: [PATCH] Add pwd policy mods to modifications list and fix exception handling

---
 opends/src/server/org/opends/server/core/ModifyOperation.java |   12 +++++++++---
 1 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/opends/src/server/org/opends/server/core/ModifyOperation.java b/opends/src/server/org/opends/server/core/ModifyOperation.java
index c665ac6..d424bdd 100644
--- a/opends/src/server/org/opends/server/core/ModifyOperation.java
+++ b/opends/src/server/org/opends/server/core/ModifyOperation.java
@@ -2361,13 +2361,19 @@
             {
                 pwPolicyState.setRequiredChangeTime();
             }
+             modifications.addAll(pwPolicyState.getModifications());
             //Apply pwd Policy modifications to modified entry.
             try {
              modifiedEntry.applyModifications(pwPolicyState.getModifications());
             } catch (DirectoryException e) {
-                //Should not happen.
-                throw new RuntimeException(e);
-            }
+                if (debugEnabled())
+                {
+                  debugCaught(DebugLogLevel.ERROR, e);
+                }
+
+                setResponseData(e);
+                break modifyProcessing;
+              }
         }
         else if(pwPolicyState.mustChangePassword())
         {

--
Gitblit v1.10.0