Fixed prevent issue(dead code)
authorJaehwan Lee <jh8379.lee@samsung.com>
Thu, 4 Apr 2013 10:49:51 +0000 (19:49 +0900)
committerJaehwan Lee <jh8379.lee@samsung.com>
Thu, 4 Apr 2013 10:49:51 +0000 (19:49 +0900)
Change-Id: I5f7fe5ec6f24f7729ca6b8f03f3459eb35e2315b
Signed-off-by: Jaehwan Lee <jh8379.lee@samsung.com>
src/wifi/FNetWifi_WifiDirectSystemAdapter.cpp

index 5f8f84e..c4d35ee 100644 (file)
@@ -1399,13 +1399,13 @@ _WifiDirectSystemAdapter::OnWifiDirectConnectionChanged(int errorCode, wifi_dire
                {
                case WIFI_DIRECT_SYSTEM_GROUP_CREATING:
                case WIFI_DIRECT_SYSTEM_CONNECTING:
+                       _WifiDirectConvertErrorResult(errorCode != WIFI_DIRECT_ERROR_NONE, r, E_SYSTEM);
+                       _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_AUTH_FAILED, r, E_AUTHENTICATION);
+                       _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_FAILED, r, E_NOT_RESPONDING);
+                       _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_TIME_OUT, r, E_REMOTE_DEVICE_NOT_FOUND);
                        if (r == E_SUCCESS && isOwner == false)
                        {
                                (void) __pWifiDirectSystemAdapter->InitializeCurrentState();
-                               _WifiDirectConvertErrorResult(errorCode != WIFI_DIRECT_ERROR_NONE, r, E_SYSTEM);
-                               _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_AUTH_FAILED, r, E_AUTHENTICATION);
-                               _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_FAILED, r, E_NOT_RESPONDING);
-                               _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_TIME_OUT, r, E_REMOTE_DEVICE_NOT_FOUND);
                                __pWifiDirectSystemAdapter->OnWifiDirectGroupCreated(peerMacAddress, r);
 
                                // OnWifiDirectConnected() does not have E_REMOTE_DEVICE_NOT_FOUND exception
@@ -1415,10 +1415,6 @@ _WifiDirectSystemAdapter::OnWifiDirectConnectionChanged(int errorCode, wifi_dire
                        else if (r != E_SUCCESS)
                        {
                                (void) __pWifiDirectSystemAdapter->InitializeCurrentState();
-                               _WifiDirectConvertErrorResult(errorCode != WIFI_DIRECT_ERROR_NONE, r, E_SYSTEM);
-                               _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_AUTH_FAILED, r, E_AUTHENTICATION);
-                               _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_FAILED, r, E_NOT_RESPONDING);
-                               _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_TIME_OUT, r, E_REMOTE_DEVICE_NOT_FOUND);
                                __pWifiDirectSystemAdapter->OnWifiDirectGroupCreated(peerMacAddress, r);
 
                                // OnWifiDirectConnected() does not have E_REMOTE_DEVICE_NOT_FOUND exception
@@ -1442,12 +1438,12 @@ _WifiDirectSystemAdapter::OnWifiDirectConnectionChanged(int errorCode, wifi_dire
 
                case WIFI_DIRECT_SYSTEM_ACTIVATED:
                        (void) __pWifiDirectSystemAdapter->InitializeCurrentState();
+                       _WifiDirectConvertErrorResult(errorCode != WIFI_DIRECT_ERROR_NONE, r, E_SYSTEM);
+                       _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_AUTH_FAILED, r, E_AUTHENTICATION);
+                       _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_FAILED, r, E_NOT_RESPONDING);
+                       _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_TIME_OUT, r, E_REMOTE_DEVICE_NOT_FOUND);
                        if (r == E_SUCCESS && isOwner == false)
                        {
-                               _WifiDirectConvertErrorResult(errorCode != WIFI_DIRECT_ERROR_NONE, r, E_SYSTEM);
-                               _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_AUTH_FAILED, r, E_AUTHENTICATION);
-                               _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_FAILED, r, E_NOT_RESPONDING);
-                               _WifiDirectConvertErrorResult(errorCode == WIFI_DIRECT_ERROR_CONNECTION_TIME_OUT, r, E_REMOTE_DEVICE_NOT_FOUND);
                                __pWifiDirectSystemAdapter->OnWifiDirectAssociationCompleted(peerMacAddress, r);
 
                                _WifiDirectConvertErrorResult(errorCode != WIFI_DIRECT_ERROR_NONE, r, E_SYSTEM);