Fix issues found by FindBugs: UL_UNRELEASED_LOCK_EXCEPTION_PATH

http://findbugs.sourceforge.net/bugDescriptions.html#UL_UNRELEASED_LOCK_EXCEPTION_PATH

Change-Id: I1c69029bd4fba6f5b61c3880a6c90ffda5e838aa
diff --git a/src/main/java/net/onrc/onos/core/intent/runtime/PathCalcRuntimeModule.java b/src/main/java/net/onrc/onos/core/intent/runtime/PathCalcRuntimeModule.java
index d6cd25a..ddfaa38 100755
--- a/src/main/java/net/onrc/onos/core/intent/runtime/PathCalcRuntimeModule.java
+++ b/src/main/java/net/onrc/onos/core/intent/runtime/PathCalcRuntimeModule.java
@@ -255,8 +255,8 @@
             //opEventChannel.removeEntry(key);
             return pathIntentOperations;
         } finally {
-            p.flushLog();
             lock.unlock();
+            p.flushLog();
         }
     }
 
@@ -398,8 +398,8 @@
             pathIntents.changeStates(pathIntentStates);
             p.log("end_changeStateByNotification");
         } finally {
-            p.flushLog();
             lock.unlock();
+            p.flushLog();
         }
     }
 }