tizen 2.4 release
[framework/security/key-manager.git] / src / manager / service / access-control.cpp
index 009e7f6..356cd97 100644 (file)
@@ -30,9 +30,7 @@ namespace CKM {
 void AccessControl::updateCCMode() {
     int fipsModeStatus = 0;
     int rc = 0;
-    bool newMode;
-
-    newMode = false;
+    bool newMode = false;
 
     if (newMode == m_ccMode)
         return;
@@ -41,17 +39,17 @@ void AccessControl::updateCCMode() {
 
     fipsModeStatus = FIPS_mode();
 
-    if(m_ccMode) {
-        if(fipsModeStatus == 0) { // If FIPS mode off
+    if (m_ccMode) {
+        if (fipsModeStatus == 0) { // If FIPS mode off
             rc = FIPS_mode_set(1); // Change FIPS_mode from off to on
-            if(rc == 0) {
+            if (rc == 0) {
                 LogError("Error in FIPS_mode_set function");
             }
         }
     } else {
-        if(fipsModeStatus == 1) { // If FIPS mode on
+        if (fipsModeStatus == 1) { // If FIPS mode on
             rc = FIPS_mode_set(0); // Change FIPS_mode from on to off
-            if(rc == 0) {
+            if (rc == 0) {
                 LogError("Error in FIPS_mode_set function");
             }
         }