prevent issue fixes
[platform/framework/native/appfw.git] / src / app / FApp_AppManagerImpl.cpp
index fe907a7..ecaf130 100755 (executable)
@@ -274,7 +274,8 @@ _AppManagerImpl::Construct(void)
        __appManagerEvent.Construct();
        __appLifecycleEvent.Construct();
        __appListForAppLifecycle.Construct(0, 0, __strHashCodeProvider, __comparer);
-       __mutex.Create();
+       result r = __mutex.Create();
+        SysTryLog(NID_APP, r == E_SUCCESS, "Creating mutex failed.");
 
        _IAppManager* pMgr = _AppManagerProxy::GetService();
        //todo : uncomment following _SysTryReturn or put assert.
@@ -1294,6 +1295,7 @@ _AppManagerImpl::RegisterAppForAppLifecycleEvent(const AppId& appId)
        SysLog(NID_APP, "Enter");
 
        result r = __mutex.Acquire();
+        SysTryLog(NID_APP, r == E_SUCCESS, "Acquiring mutex failed.");
 
        bool isContained = false;
        r = __appListForAppLifecycle.ContainsKey(appId, isContained);
@@ -1315,6 +1317,7 @@ _AppManagerImpl::RegisterAppForAppLifecycleEvent(const AppId& appId)
                SysLog(NID_APP, "The appId(%ls) is registered.", appId.GetPointer());
        }
        r = __mutex.Release();
+        SysTryLog(NID_APP, r == E_SUCCESS, "Releasing mutex failed.");
        
        SysLog(NID_APP, "Exit");
 
@@ -1327,6 +1330,7 @@ _AppManagerImpl::UnregisterAppForAppLifecycleEvent(const AppId& appId)
        SysLog(NID_APP, "Enter");
 
        result r = __mutex.Acquire();
+        SysTryLog(NID_APP, r == E_SUCCESS, "Acquiring mutex failed.");
        
        bool isContained = false;
        r = __appListForAppLifecycle.ContainsKey(appId, isContained);
@@ -1360,6 +1364,7 @@ _AppManagerImpl::UnregisterAppForAppLifecycleEvent(const AppId& appId)
        }
        
        r = __mutex.Release();
+        SysTryLog(NID_APP, r == E_SUCCESS, "Releasing mutex failed.");
        
        SysLog(NID_APP, "Exit");