coverity issues fix 76/215276/1 accepted/tizen_5.5_unified_mobile_hotfix tizen_5.5_mobile_hotfix tizen_5.5_tv accepted/tizen/5.5/unified/20191031.030942 accepted/tizen/5.5/unified/mobile/hotfix/20201027.082150 accepted/tizen/unified/20191006.223703 submit/tizen/20191004.132602 submit/tizen_5.5/20191031.000002 submit/tizen_5.5_mobile_hotfix/20201026.185101 tizen_5.5.m2_release
authorsrinivasa.m <srinivasa.m@samsung.com>
Fri, 4 Oct 2019 11:28:12 +0000 (16:58 +0530)
committersrinivasa.m <srinivasa.m@samsung.com>
Fri, 4 Oct 2019 11:28:12 +0000 (16:58 +0530)
Change-Id: Ia387481e5fc7d59df48cdd9bbee718026c597016

common/fido_json_handler.c

index 3b8e4b2..7ea1fa5 100755 (executable)
@@ -1112,8 +1112,9 @@ _uaf_parser_parse_asm_response_discover(GList *asm_response_list, int *error_cod
                                        char *auth_idx_str = (char*)calloc(1, 128);
                                        if(auth_idx_str == NULL) {
                                                SAFE_DELETE(auth_info);
+                                               goto CATCH;
                                        }
-                                       CATCH_IF_FAIL(auth_idx_str != NULL);
+
                                        snprintf(auth_idx_str, 127, "%d", auth_index);
 
                                        auth_info->auth_index = auth_idx_str;
@@ -3189,8 +3190,9 @@ _uaf_parser_parser_asm_get_reg_response(const char *get_reg_resp)
                                _asm_app_reg_t *app_reg = (_asm_app_reg_t*) calloc(1, sizeof(_asm_app_reg_t));
                                if(app_reg == NULL) {
                                        g_list_free_full(key_id_list, free);
+                                       goto CATCH;
                                }
-                               CATCH_IF_FAIL(app_reg != NULL);
+
                                if (app_id != NULL) {
                                        _INFO("app_id = [%s]", app_id);
                                        app_reg->app_id = strdup(app_id);