Resolved coverity issue 77/215477/2 accepted/tizen_5.5_unified accepted/tizen_5.5_unified_mobile_hotfix accepted/tizen_5.5_unified_wearable_hotfix accepted/tizen_6.0_unified accepted/tizen_6.0_unified_hotfix tizen_5.5 tizen_5.5_mobile_hotfix tizen_5.5_tv tizen_5.5_wearable_hotfix tizen_6.0_hotfix accepted/tizen/5.5/unified/20191031.033703 accepted/tizen/5.5/unified/mobile/hotfix/20201027.071047 accepted/tizen/5.5/unified/wearable/hotfix/20201027.094918 accepted/tizen/6.0/unified/20201030.103206 accepted/tizen/6.0/unified/20211029.081530 accepted/tizen/6.0/unified/hotfix/20201103.045122 accepted/tizen/unified/20191014.062430 submit/tizen/20191014.051341 submit/tizen_5.5/20191031.000009 submit/tizen_5.5/20191031.000011 submit/tizen_5.5/20191031.000013 submit/tizen_5.5_mobile_hotfix/20201026.185109 submit/tizen_5.5_wearable_hotfix/20201026.184309 submit/tizen_6.0/20201029.205505 submit/tizen_6.0/20211029.144301 submit/tizen_6.0_hotfix/20201102.192905 submit/tizen_6.0_hotfix/20201103.115105 tizen_5.5.m2_release tizen_6.0.m2_release
authorRandeep Singh <randeep.s@samsung.com>
Wed, 9 Oct 2019 05:57:41 +0000 (11:27 +0530)
committerRandeep Singh <randeep.s@samsung.com>
Wed, 9 Oct 2019 06:03:01 +0000 (06:03 +0000)
Change-Id: I34c86263a5db4c604c8421c693792a382ea20856
Signed-off-by: Randeep Singh <randeep.s@samsung.com>
src/ad-id.c

index 85effe9..340e2cf 100644 (file)
@@ -216,7 +216,9 @@ _text_get_cb(void *data, Evas_Object *obj, const char *part)
                case 2:
                        adid = vconf_get_str(VCONFKEY_SETAPPL_AD_ID);
                        AI_LOGD("adid: %s", adid);
-                       return strdup(adid);
+                       char *temp = strdup(adid);
+                       free(adid);
+                       return temp;
                case 3:
                        return strdup(dgettext(AD_ID_APP_NAME, "IDS_ST_SBODY_CREATE_A_NEW_USER_PROFILE_BY_GENERATING_A_NEW_ADVERTISING_ID_ABB"));
                case 4: