Change-Id: I40e8f5bfe244f6b1c8f1e323afad90067065029d
26 files changed:
} else {
SETTING_TRACE_ERROR("ad->item_dev_name is NULL");
}
} else {
SETTING_TRACE_ERROR("ad->item_dev_name is NULL");
}
// [UI] My number
int err;
// [UI] My number
int err;
Setting_GenGroupItem_Data *item_data = NULL;
for(; i < ad->my_numbers.count; i++) {
Setting_GenGroupItem_Data *item_data = NULL;
for(; i < ad->my_numbers.count; i++) {
- if (ad->my_numbers.list[i].num == NULL) {
+ if (ad->my_numbers.list[i].num[0] == '\0') {
BOOL_SLP_SETTING_ACCESSIBILITY_ACCEPT_CALL,
BOOL_SLP_SETTING_ACCESSIBILITY_POWERKEY_END_CALLS,
BOOL_SLP_SETTING_ACCESSIBILITY_ACCEPT_CALL,
BOOL_SLP_SETTING_ACCESSIBILITY_POWERKEY_END_CALLS,
- // data usage
- BOOL_SLP_SETTING_DATAUSAGE_MOBILE_DATA_BOOL,
- BOOL_SLP_SETTING_DATAUSAGE_DISABLE_MOBILE_DATA_AT_LIMIT_BOOL,
- BOOL_SLP_SETTING_DATAUSAGE_RESTRICT_BG_DATA_BOOL,
- BOOL_SLP_SETTING_DATAUSAGE_SHOW_WIFI_USAGE_BOOL,
/* end */
SETTING_BOOL_SLP_LIST_MAX
} setting_bool_slp_list;
/* end */
SETTING_BOOL_SLP_LIST_MAX
} setting_bool_slp_list;
SETTING_TRACE_ERROR(" libug-%s.so is *NOT* present, so skip it..\n", ug_name);
//return FALSE;
is_installed_in_usr = false;
SETTING_TRACE_ERROR(" libug-%s.so is *NOT* present, so skip it..\n", ug_name);
//return FALSE;
is_installed_in_usr = false;
+ } else {
+ is_installed_in_usr = true;
+ } else {
+ is_installed_in_usr = true;
- is_installed_in_usr = true;
//2.first do exist-checking in /opt/ug/lib
//char ug_file[PATH_MAX + 1];
//2.first do exist-checking in /opt/ug/lib
//char ug_file[PATH_MAX + 1];
SETTING_TRACE_ERROR(" libug-%s.so is *NOT* present, so skip it..\n", ug_name);
//return FALSE;
is_installed_in_opt = false;
SETTING_TRACE_ERROR(" libug-%s.so is *NOT* present, so skip it..\n", ug_name);
//return FALSE;
is_installed_in_opt = false;
+ } else {
+ is_installed_in_opt = true;
+ } else {
+ is_installed_in_opt = true;
- is_installed_in_opt = true;
- return (is_installed_in_opt || is_installed_in_opt);
+ FREE(ug_name);
+ return (is_installed_in_usr || is_installed_in_opt);
}
/*other relative function*/
}
/*other relative function*/
{BOOL_SLP_SETTING_ACCESSIBILITY_ACCEPT_CALL, VCONFKEY_CISSAPPL_ANSWERING_KEY_BOOL, eBOOL,{0}, export_default, import_default},
{BOOL_SLP_SETTING_ACCESSIBILITY_POWERKEY_END_CALLS, VCONFKEY_CISSAPPL_POWER_KEY_ENDS_CALL_BOOL, eBOOL,{0}, export_default, import_default},
{BOOL_SLP_SETTING_ACCESSIBILITY_ACCEPT_CALL, VCONFKEY_CISSAPPL_ANSWERING_KEY_BOOL, eBOOL,{0}, export_default, import_default},
{BOOL_SLP_SETTING_ACCESSIBILITY_POWERKEY_END_CALLS, VCONFKEY_CISSAPPL_POWER_KEY_ENDS_CALL_BOOL, eBOOL,{0}, export_default, import_default},
- //datausage
- //{BOOL_SLP_SETTING_DATAUSAGE_SET_DATA_USAGE_LIMIT_BOOL, VCONFKEY_SETAPPL_SET_DATA_USAGE_LIMIT_BOOL, eBOOL, {0}, export_default, import_default},
-
//------------------------------------------------------------------------------------------------
{SETTING_BOOL_SLP_LIST_MAX, NULL, eBOOL, {0}, export_default, import_default},
//------------------------------------------------------------------------------------------------
{SETTING_BOOL_SLP_LIST_MAX, NULL, eBOOL, {0}, export_default, import_default},
if (lbutton_str)
{
lbtn = setting_create_button(navigate_bar, lbutton_str, NAVI_DEF_BUTTON_STYLE, lbutton_click_cb, cb_data);
if (lbutton_str)
{
lbtn = setting_create_button(navigate_bar, lbutton_str, NAVI_DEF_BUTTON_STYLE, lbutton_click_cb, cb_data);
- elm_object_item_part_content_set(navi_it, has_btn_flag ? "toolbar_button2" : "toolbar_button1", lbtn);
+ elm_object_item_part_content_set(navi_it, "toolbar_button1", lbtn);
has_btn_flag = TRUE;
}
if (mbutton_str)
has_btn_flag = TRUE;
}
if (mbutton_str)
if (lbutton_str)
{
lbtn = setting_create_button(navigate_bar, lbutton_str, NAVI_DEF_BUTTON_STYLE, lbutton_click_cb, cb_data);
if (lbutton_str)
{
lbtn = setting_create_button(navigate_bar, lbutton_str, NAVI_DEF_BUTTON_STYLE, lbutton_click_cb, cb_data);
- elm_object_item_part_content_set(navi_it, has_btn_flag ? "toolbar_button2" : "toolbar_button1", lbtn);
+ elm_object_item_part_content_set(navi_it, "toolbar_button1", lbtn);
has_btn_flag = TRUE;
}
if (mbutton_str)
has_btn_flag = TRUE;
}
if (mbutton_str)
//counting.
int i = 0;
if (state & VCONFKEY_TELEPHONY_DISP_SPN) {
//counting.
int i = 0;
if (state & VCONFKEY_TELEPHONY_DISP_SPN) {
- if( i != 0)
- g_strlcat(name, " - ", MAX_COMMON_BUFFER_LEN);
-
kv = vconf_get_str(VCONFKEY_TELEPHONY_SPN_NAME);
g_strlcat(name, kv, MAX_COMMON_BUFFER_LEN);
FREE(kv);
kv = vconf_get_str(VCONFKEY_TELEPHONY_SPN_NAME);
g_strlcat(name, kv, MAX_COMMON_BUFFER_LEN);
FREE(kv);
char *pa_region = vconf_get_str(VCONFKEY_LANGSET);
char* pa_sub = substring(pa_region, 0, 4);
SETTING_TRACE(" main - region set from ug result : %s", pa_sub);
char *pa_region = vconf_get_str(VCONFKEY_LANGSET);
char* pa_sub = substring(pa_region, 0, 4);
SETTING_TRACE(" main - region set from ug result : %s", pa_sub);
uloc_setDefault(pa_region, &err);
SETTING_TRACE("errorcode %d ", err);
FREE(pa_region);
uloc_setDefault(pa_region, &err);
SETTING_TRACE("errorcode %d ", err);
FREE(pa_region);
// 2. call brightness set API
int value = SETTING_BRIGHTNESS_LEVEL5;
//device_get_brightness(BRIGHTNESS_DISPLAY, &value);
// 2. call brightness set API
int value = SETTING_BRIGHTNESS_LEVEL5;
//device_get_brightness(BRIGHTNESS_DISPLAY, &value);
value = elm_slider_value_get(ad->data_br_sli->eo_check);
value = elm_slider_value_get(ad->data_br_sli->eo_check);
- SETTING_TRACE(" value of ad->data_br_sli->eo_check: %d ", value);
- setting_enable_genlist_item(ad->data_br_sli->item);
+ SETTING_TRACE(" value of ad->data_br_sli->eo_check: %d ", value);
+ setting_enable_genlist_item(ad->data_br_sli->item);
+ }
ret = setting_set_int_slp_key(INT_SLP_SETTING_LCD_BRIGHTNESS, value, &err);
if (0 != ret) //add error handle,due to different target env..
ret = setting_set_int_slp_key(INT_SLP_SETTING_LCD_BRIGHTNESS, value, &err);
if (0 != ret) //add error handle,due to different target env..
#else
int value = SETTING_BRIGHTNESS_LEVEL5;
//device_get_brightness(BRIGHTNESS_DISPLAY, &value);
#else
int value = SETTING_BRIGHTNESS_LEVEL5;
//device_get_brightness(BRIGHTNESS_DISPLAY, &value);
- if (ad->data_br_sli) value = elm_slider_value_get(ad->data_br_sli->eo_check);
- SETTING_TRACE(" value of ad->data_br_sli->eo_check: %d ", value);
- setting_enable_genlist_item(ad->data_br_sli->item);
+ if (ad->data_br_sli) {
+ value = elm_slider_value_get(ad->data_br_sli->eo_check);
+ SETTING_TRACE(" value of ad->data_br_sli->eo_check: %d ", value);
+ setting_enable_genlist_item(ad->data_br_sli->item);
+ }
ret = setting_set_int_slp_key(INT_SLP_SETTING_LCD_BRIGHTNESS, value, &err);
if (0 != ret) //add error handle,due to different target env..
{
ret = setting_set_int_slp_key(INT_SLP_SETTING_LCD_BRIGHTNESS, value, &err);
if (0 != ret) //add error handle,due to different target env..
{
if (!ad || !ad->data_br_sli || !ad->data_br_sli->eo_check)
{
SETTING_TRACE_ERROR("!ad || !ad->data_br_sli || !ad->data_br_sli->eo_check");
if (!ad || !ad->data_br_sli || !ad->data_br_sli->eo_check)
{
SETTING_TRACE_ERROR("!ad || !ad->data_br_sli || !ad->data_br_sli->eo_check");
+ if (ad)
+ ad->set_idler = NULL;
return FALSE;
}
//Get the current real value of slider
return FALSE;
}
//Get the current real value of slider
}
struct ug_cbs *cbs = (struct ug_cbs *)calloc(1, sizeof(struct ug_cbs));
}
struct ug_cbs *cbs = (struct ug_cbs *)calloc(1, sizeof(struct ug_cbs));
- setting_retm_if(cbs == NULL, "calloc failed");
+ if (!cbs) {
+ service_destroy(service);
+ return;
+ }
cbs->layout_cb = setting_display_layout_ug_cb;
cbs->result_cb = __setting_display_wallpaper_imageviewer_ug_result_cb;
cbs->layout_cb = setting_display_layout_ug_cb;
cbs->result_cb = __setting_display_wallpaper_imageviewer_ug_result_cb;
}
setting_view_fileview_main.is_create = 1;
}
setting_view_fileview_main.is_create = 1;
return SETTING_RETURN_SUCCESS;
}
return SETTING_RETURN_SUCCESS;
}
else if (ad->viewmode == FONT_SIZE_VIEW_APPCONTROL)
{
service_h svc;
else if (ad->viewmode == FONT_SIZE_VIEW_APPCONTROL)
{
service_h svc;
- if (service_create(&svc))
- return;
int err;
int ret = setting_set_int_slp_key(INT_SLP_SETTING_ACCESSIBILITY_FONT_SIZE, ad->ret_font_size, &err);
setting_retm_if(ret == -1, "Failed to set vconf");
int err;
int ret = setting_set_int_slp_key(INT_SLP_SETTING_ACCESSIBILITY_FONT_SIZE, ad->ret_font_size, &err);
setting_retm_if(ret == -1, "Failed to set vconf");
+ if (service_create(&svc))
+ return;
+
char font_size[SETTING_FONT_MAX_LEN] = {0,};
snprintf(font_size, SETTING_FONT_MAX_LEN, "%d", ad->ret_font_size);
char font_size[SETTING_FONT_MAX_LEN] = {0,};
snprintf(font_size, SETTING_FONT_MAX_LEN, "%d", ad->ret_font_size);
setting_retvm_if(NULL == cb, SETTING_RETURN_FAIL, "cb is NULL");
SettingMemoryUG *ad = (SettingMemoryUG *)data;
if (ad->mmc_content == NULL) {
setting_retvm_if(NULL == cb, SETTING_RETURN_FAIL, "cb is NULL");
SettingMemoryUG *ad = (SettingMemoryUG *)data;
if (ad->mmc_content == NULL) {
- ad->mmc_content = (struct mmc_contents *)calloc(1, sizeof(struct mmc_contents *));
+ ad->mmc_content = (struct mmc_contents *)calloc(1, sizeof(struct mmc_contents));
if (ad->mmc_content == NULL ) {
SETTING_TRACE_ERROR("calloc failed");
return SETTING_RETURN_FAIL;
if (ad->mmc_content == NULL ) {
SETTING_TRACE_ERROR("calloc failed");
return SETTING_RETURN_FAIL;
ret = ail_filter_add_str(filter, AIL_PROP_CATEGORIES_STR, "home-screen");
if (ret != AIL_ERROR_OK) {
ret = ail_filter_add_str(filter, AIL_PROP_CATEGORIES_STR, "home-screen");
if (ret != AIL_ERROR_OK) {
+ ail_filter_destroy(filter);
+ return ;
}
ail_filter_list_appinfo_foreach(filter, appinfo_menuscreen_func, (void *)ugd);
}
ail_filter_list_appinfo_foreach(filter, appinfo_menuscreen_func, (void *)ugd);
int err = connection_get_profile_iterator(ad->connection, CONNECTION_ITERATOR_TYPE_REGISTERED, &profile_iter);
if (err != CONNECTION_ERROR_NONE) {
SETTING_TRACE_ERROR("Fail to get profile iterator [%d]", err);
int err = connection_get_profile_iterator(ad->connection, CONNECTION_ITERATOR_TYPE_REGISTERED, &profile_iter);
if (err != CONNECTION_ERROR_NONE) {
SETTING_TRACE_ERROR("Fail to get profile iterator [%d]", err);
connection_profile_set_cellular_home_url(con_info, URL_HEAD);
} else {
if (!safeStrCmp(home, "")) {
connection_profile_set_cellular_home_url(con_info, URL_HEAD);
} else {
if (!safeStrCmp(home, "")) {
home = strdup(URL_HEAD);
ret = SETTING_DNET_RETURN_NULL_HOMEURL;
}
home = strdup(URL_HEAD);
ret = SETTING_DNET_RETURN_NULL_HOMEURL;
}
network_table[i]);
if ('\0' == ad->search_text[0]
network_table[i]);
if ('\0' == ad->search_text[0]
- || (one_item->name && is_substr_ncase(one_item->name, ad->search_text))) { /* is substring */
+ || ('\0' == one_item->name[0] && is_substr_ncase(one_item->name, ad->search_text))) { /* is substring */
/* SETTING_TRACE("Adding item[%s]", one_item->name); */
/* SETTING_TRACE("ad->gl_network:%p", ad->gl_network); */
gl_item =
/* SETTING_TRACE("Adding item[%s]", one_item->name); */
/* SETTING_TRACE("ad->gl_network:%p", ad->gl_network); */
gl_item =
setting_hide_input_pannel_cb(ad->ed_pw1->eo_check);
}
if (ad->ed_pw2) {
setting_hide_input_pannel_cb(ad->ed_pw1->eo_check);
}
if (ad->ed_pw2) {
- setting_hide_input_pannel_cb(ad->ed_pw1->eo_check);
+ setting_hide_input_pannel_cb(ad->ed_pw2->eo_check);
- setting_hide_input_pannel_cb(ad->ed_pw1->eo_check);
+ setting_hide_input_pannel_cb(ad->ed_pw3->eo_check);
SettingPasswordUG *ad = (SettingPasswordUG *) data;
service_h svc;
SettingPasswordUG *ad = (SettingPasswordUG *) data;
service_h svc;
- if (service_create(&svc))
- return;
SETTING_TRACE("ad->view_type:%d", ad->view_type);
SETTING_TRACE("ad->view_type:%d", ad->view_type);
-
- service_add_extra_data(svc, "result", ad->view_type_string);
- ug_send_result(ad->ug, svc);
- SETTING_TRACE("Send Result : %s\n", ad->view_type_string);
-
- service_destroy(svc);
- /* Send destroy request */
- ug_destroy_me(ad->ug);
setting_password_ug_create_popup_notitle_nobtn(ad, tmp_str, TRUE);
}
}
setting_password_ug_create_popup_notitle_nobtn(ad, tmp_str, TRUE);
}
}
case SIM_PIN1_CHANGE_FAIL:
case SIM_PIN2_CHANGE_FAIL:
setting_password_ug_create_popup_notitle_nobtn(ad,
case SIM_PIN1_CHANGE_FAIL:
case SIM_PIN2_CHANGE_FAIL:
setting_password_ug_create_popup_notitle_nobtn(ad,
SETTING_TRACE_ERROR("ad->data_br_sli is NULL");
}
SETTING_TRACE_ERROR("ad->data_br_sli is NULL");
}
+ if (auto_value && ad->data_br_sli) {
setting_disable_genlist_item(ad->data_br_sli->item);
}
setting_disable_genlist_item(ad->data_br_sli->item);
}
int response_type = btn_type(obj);
SettingPowersavingUG *ad = (SettingPowersavingUG *) data;
if (POPUP_RESPONSE_OK == response_type) { //need set vconf
int response_type = btn_type(obj);
SettingPowersavingUG *ad = (SettingPowersavingUG *) data;
if (POPUP_RESPONSE_OK == response_type) { //need set vconf
- int err =
- vconf_set_bool(VCONFKEY_SETAPPL_PWRSV_SYSMODE_STATUS,
- ad->data_powersaving_active->chk_status);
- if (0 != err) { //if set failed, need rollback
- SETTING_TRACE_ERROR("Set vconf Failed");
- if (ad->data_powersaving_active) {
+ if (ad->data_powersaving_active) {
+ int err =
+ vconf_set_bool(VCONFKEY_SETAPPL_PWRSV_SYSMODE_STATUS,
+ ad->data_powersaving_active->chk_status);
+ if (0 != err) { //if set failed, need rollback
+ SETTING_TRACE_ERROR("Set vconf Failed");
ad->data_powersaving_active->chk_status =
ad->data_powersaving_active->chk_status =
- !ad->data_powersaving_active->chk_status;
+ !ad->data_powersaving_active->chk_status;
- data_powersaving_active->
- eo_check,
- ad->
- data_powersaving_active->
- chk_status);
+ data_powersaving_active->
+ eo_check,
+ ad->
+ data_powersaving_active->
+ chk_status);
+ return;
- return;
- }
- if (ad->data_powersaving_active->chk_status) {//powersaving is on
- int pwrsv_vib = 0;
- vconf_get_bool(VCONFKEY_SETAPPL_PWRSV_CUSTMODE_SCREEN_VIB, &pwrsv_vib);
- if (pwrsv_vib){
+ if (ad->data_powersaving_active->chk_status) {//powersaving is on
+ int pwrsv_vib = 0;
+ vconf_get_bool(VCONFKEY_SETAPPL_PWRSV_CUSTMODE_SCREEN_VIB, &pwrsv_vib);
+ if (pwrsv_vib){
+ //touch feedback virbration
+ int value = 0;
+ vconf_get_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_INT, &value);
+ vconf_set_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_BAK_INT, value);//backup
+ vconf_set_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_INT, 0);
+ }
+ } else {//powersaving is off
//touch feedback virbration
int value = 0;
//touch feedback virbration
int value = 0;
- vconf_get_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_INT, &value);
- vconf_set_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_BAK_INT, value);//backup
- vconf_set_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_INT, 0);
+ vconf_get_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_BAK_INT, &value);
+ vconf_set_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_INT, value);
- } else {//powersaving is off
- //touch feedback virbration
- int value = 0;
- vconf_get_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_BAK_INT, &value);
- vconf_set_int(VCONFKEY_SETAPPL_TOUCH_FEEDBACK_VIBRATION_LEVEL_INT, value);
- }
- if (ad->popup_chk && elm_check_state_get(ad->popup_chk)) {
- (void)
- vconf_set_bool
- (VCONFKEY_SETAPPL_PWRSV_SYSMODE_STATUS_REMINDER,
- FALSE);
+ if (ad->popup_chk && elm_check_state_get(ad->popup_chk)) {
+ (void)
+ vconf_set_bool
+ (VCONFKEY_SETAPPL_PWRSV_SYSMODE_STATUS_REMINDER,
+ FALSE);
+ }
} else if (POPUP_RESPONSE_CANCEL == response_type) { //need rollback
if (ad->data_powersaving_active) {
ad->data_powersaving_active->chk_status =
} else if (POPUP_RESPONSE_CANCEL == response_type) { //need rollback
if (ad->data_powersaving_active) {
ad->data_powersaving_active->chk_status =
+ if(pa_tone_path) {
+ free(pa_tone_path);
+ pa_tone_path = NULL;
+ }
FREE(cbs);
/** @todo verify it's valid */
FREE(cbs);
/** @todo verify it's valid */
- if(pa_cur_ringtone)
- FREE(pa_cur_ringtone);
+ if(pa_cur_ringtone) {
+ free(pa_cur_ringtone);
+ pa_cur_ringtone = NULL;
+ }
__setting_profile_ug_key_ungrab(ad);
return;
__setting_profile_ug_key_ungrab(ad);
return;
else if (!safeStrCmp(vconf_name, VCONFKEY_SETAPPL_NOTI_MSG_ALERT_REP_TYPE_INT)) {
status = vconf_keynode_get_int(key);
else if (!safeStrCmp(vconf_name, VCONFKEY_SETAPPL_NOTI_MSG_ALERT_REP_TYPE_INT)) {
status = vconf_keynode_get_int(key);
- if(ad->data_msg_alert_repeat)
+ if(status >= 0 && ad->data_msg_alert_repeat)
{
ad->data_msg_alert_repeat->sub_desc = (char*)g_strdup(_(repeat_type[status]));
elm_genlist_item_update(ad->data_msg_alert_repeat->item);
{
ad->data_msg_alert_repeat->sub_desc = (char*)g_strdup(_(repeat_type[status]));
elm_genlist_item_update(ad->data_msg_alert_repeat->item);
else if (!safeStrCmp(vconf_name, VCONFKEY_SETAPPL_NOTI_EMAIL_ALERT_REP_TYPE_INT)) {
status = vconf_keynode_get_int(key);
else if (!safeStrCmp(vconf_name, VCONFKEY_SETAPPL_NOTI_EMAIL_ALERT_REP_TYPE_INT)) {
status = vconf_keynode_get_int(key);
- if(ad->data_email_alert_repeat)
+ if(status >= 0 && ad->data_email_alert_repeat)
{
ad->data_email_alert_repeat->sub_desc = (char*)g_strdup(_(repeat_type[status]));
elm_genlist_item_update(ad->data_email_alert_repeat->item);
{
ad->data_email_alert_repeat->sub_desc = (char*)g_strdup(_(repeat_type[status]));
elm_genlist_item_update(ad->data_email_alert_repeat->item);
profileUG->data_call_alert_tone->sub_desc = setting_file_basename(pa_tone_path);
elm_genlist_item_update(profileUG->data_call_alert_tone->item);
}
profileUG->data_call_alert_tone->sub_desc = setting_file_basename(pa_tone_path);
elm_genlist_item_update(profileUG->data_call_alert_tone->item);
}
+ if (pa_tone_path) {
+ free(pa_tone_path);
+ pa_tone_path = NULL;
+ }
}
/* 2. message ringtone */
}
/* 2. message ringtone */
profileUG->data_msg_alert_tone->sub_desc = setting_file_basename(pa_tone_path);
elm_genlist_item_update(profileUG->data_msg_alert_tone->item);
}
profileUG->data_msg_alert_tone->sub_desc = setting_file_basename(pa_tone_path);
elm_genlist_item_update(profileUG->data_msg_alert_tone->item);
}
+ if (pa_tone_path) {
+ free(pa_tone_path);
+ pa_tone_path = NULL;
+ }
}
/* 3. email ringtone */
}
/* 3. email ringtone */
profileUG->data_email_alert_tone->sub_desc = setting_file_basename(pa_tone_path);
elm_genlist_item_update(profileUG->data_email_alert_tone->item);
}
profileUG->data_email_alert_tone->sub_desc = setting_file_basename(pa_tone_path);
elm_genlist_item_update(profileUG->data_email_alert_tone->item);
}
+ if (pa_tone_path) {
+ free(pa_tone_path);
+ pa_tone_path = NULL;
+ }
(char *)item_name,
(char *)result_str, NULL);
ecore_idler_add((Ecore_Task_Cb) __delay_reset_location, item_data);
(char *)item_name,
(char *)result_str, NULL);
ecore_idler_add((Ecore_Task_Cb) __delay_reset_location, item_data);
+
+ service_destroy(svc);
+ FREE(path);
setting_retvm_if(NULL == cb, SETTING_RETURN_FAIL, "cb is NULL");
SettingStorageUG *ad = (SettingStorageUG *)data;
if (ad->mmc_content == NULL) {
setting_retvm_if(NULL == cb, SETTING_RETURN_FAIL, "cb is NULL");
SettingStorageUG *ad = (SettingStorageUG *)data;
if (ad->mmc_content == NULL) {
- ad->mmc_content = (struct mmc_contents *)calloc(1, sizeof(struct mmc_contents *));
+ ad->mmc_content = (struct mmc_contents *)calloc(1, sizeof(struct mmc_contents));
if (ad->mmc_content == NULL ) {
SETTING_TRACE_ERROR("calloc failed");
return SETTING_RETURN_FAIL;
if (ad->mmc_content == NULL ) {
SETTING_TRACE_ERROR("calloc failed");
return SETTING_RETURN_FAIL;
pthread_mutex_init(&ad->update_mutex, NULL);
pthread_cond_init(&ad->wait_cond, NULL);
pthread_mutex_init(&ad->update_mutex, NULL);
pthread_cond_init(&ad->wait_cond, NULL);
+ pthread_mutex_lock(&ad->exit_mutex);
ad->exit_flag = EINA_FALSE;
ad->exit_flag = EINA_FALSE;
+ pthread_mutex_unlock(&ad->exit_mutex);
+
+ pthread_mutex_lock(&ad->update_mutex);
ad->type = SETTING_STORAGE_PICTURES_VIDEO;
ad->type = SETTING_STORAGE_PICTURES_VIDEO;
+ pthread_mutex_unlock(&ad->update_mutex);
ad->internal_status.dAvail = 0.0;
ad->internal_status.dTotal= 0.0;
ad->internal_status.dAvail = 0.0;
ad->internal_status.dTotal= 0.0;
char* timezone_str = get_timezone_str();
char* timezone_str = get_timezone_str();
- bool ret = get_city_name(timezone_str);
+ ret = get_city_name(timezone_str);
if (ret) {
SETTING_TRACE(">>>>>> RESULT : %s", get_city_name_result());
}
if (ret) {
SETTING_TRACE(">>>>>> RESULT : %s", get_city_name_result());
}
ail_filter_h f;
DrawAppInfo* pinfo = (DrawAppInfo*)malloc(sizeof(DrawAppInfo));
ail_filter_h f;
DrawAppInfo* pinfo = (DrawAppInfo*)malloc(sizeof(DrawAppInfo));
- pinfo->ncount = 0;
- pinfo->draw_app = draw_3rdapp;
- pinfo->data = ad;
- if (ail_filter_new(&f) == AIL_ERROR_OK)
- {
- if (ail_filter_add_bool(f, AIL_PROP_NODISPLAY_BOOL, false) != AIL_ERROR_OK)
+ if (pinfo) {
+ pinfo->ncount = 0;
+ pinfo->draw_app = draw_3rdapp;
+ pinfo->data = ad;
+
+ if (ail_filter_new(&f) == AIL_ERROR_OK)
- SETTING_TRACE("ail filter error");
- return 0;
- }
+ if (ail_filter_add_bool(f, AIL_PROP_NODISPLAY_BOOL, false) != AIL_ERROR_OK)
+ {
+ SETTING_TRACE("ail filter error");
- ail_filter_list_appinfo_foreach(f, __download_apps_cb, pinfo);
- //---------------------------------------------------------------
- ail_filter_destroy(f);
- }
- ncount = pinfo->ncount;
+ free(pinfo);
+ pinfo = NULL;
+
+ ail_filter_destroy(f);
+ return 0;
+ }
+
+ ail_filter_list_appinfo_foreach(f, __download_apps_cb, pinfo);
+ //---------------------------------------------------------------
+ ail_filter_destroy(f);
+ }
+ ncount = pinfo->ncount;
free(pinfo);
pinfo = NULL;
}
free(pinfo);
pinfo = NULL;
}
_g_drawer_list = eina_list_append(_g_drawer_list, node);
}
_g_drawer_list = eina_list_append(_g_drawer_list, node);
}
// received key : checkbox1|N/A , value : INT|1
//-------------------------------------------------------------
//char* key = "checkbox1|N/A";
// received key : checkbox1|N/A , value : INT|1
//-------------------------------------------------------------
//char* key = "checkbox1|N/A";
- char* ptr = strchr(key, '|');
+ char* ptr = NULL;
+
+ if (key) {
+ ptr = strchr(key, '|');
+ }
xmlDocPtr doc = NULL;
if (ptr && key)
xmlDocPtr doc = NULL;
if (ptr && key)
static void* group_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
static void* group_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
- ret_if(!data || !xmlObj);
+ retv_if(!data || !xmlObj, NULL);
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
static void* __link_list_cb(void *data, Evas_Object *obj, void *event_info)
{
SETTING_TRACE_BEGIN;
static void* __link_list_cb(void *data, Evas_Object *obj, void *event_info)
{
SETTING_TRACE_BEGIN;
- ret_if(data == NULL);
- retm_if(event_info == NULL, "Invalid argument: event info is NULL");
+ retv_if(data == NULL, NULL);
+ retvm_if(event_info == NULL, NULL, "Invalid argument: event info is NULL");
Elm_Object_Item *item = (Elm_Object_Item *) event_info;
elm_genlist_item_selected_set(item, 0);
Setting_GenGroupItem_Data *list_item =
(Setting_GenGroupItem_Data *) elm_object_item_data_get(item);
xmlNode* xmlObj = data;
Elm_Object_Item *item = (Elm_Object_Item *) event_info;
elm_genlist_item_selected_set(item, 0);
Setting_GenGroupItem_Data *list_item =
(Setting_GenGroupItem_Data *) elm_object_item_data_get(item);
xmlNode* xmlObj = data;
+ retv_if(!xmlObj, NULL);
const char *link_file = (char*)xmlGetProp(xmlObj, "value");
if(!link_file)
{
SETTING_TRACE_ERROR("Invalidate liked file");
const char *link_file = (char*)xmlGetProp(xmlObj, "value");
if(!link_file)
{
SETTING_TRACE_ERROR("Invalidate liked file");
}
char file[1024] = {0,};
snprintf(file, sizeof(file), "%s/%s", PLUGIN_CFG_DIR, link_file);
}
char file[1024] = {0,};
snprintf(file, sizeof(file), "%s/%s", PLUGIN_CFG_DIR, link_file);
static void* __launch_list_cb(void *data, Evas_Object *obj, void *event_info)
{
SETTING_TRACE_BEGIN;
static void* __launch_list_cb(void *data, Evas_Object *obj, void *event_info)
{
SETTING_TRACE_BEGIN;
- ret_if(data == NULL);
- retm_if(event_info == NULL, "Invalid argument: event info is NULL");
+ retv_if(data == NULL, NULL);
+ retvm_if(event_info == NULL, NULL, "Invalid argument: event info is NULL");
Elm_Object_Item *item = (Elm_Object_Item *) event_info;
elm_genlist_item_selected_set(item, 0);
Setting_GenGroupItem_Data *list_item =
(Setting_GenGroupItem_Data *) elm_object_item_data_get(item);
xmlNode* xmlObj = data;
Elm_Object_Item *item = (Elm_Object_Item *) event_info;
elm_genlist_item_selected_set(item, 0);
Setting_GenGroupItem_Data *list_item =
(Setting_GenGroupItem_Data *) elm_object_item_data_get(item);
xmlNode* xmlObj = data;
+ retv_if(!xmlObj, NULL);
const char *key_str = (char*)xmlGetProp(xmlObj, "id");
const char *title_str = (char*)xmlGetProp(xmlObj, "title");
const char *appid_str = (char*)xmlGetProp(xmlObj, "appid");
const char *key_str = (char*)xmlGetProp(xmlObj, "id");
const char *title_str = (char*)xmlGetProp(xmlObj, "title");
const char *appid_str = (char*)xmlGetProp(xmlObj, "appid");
static void* label_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
static void* label_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
- ret_if(!data || !xmlObj);
+ retv_if(!data || !xmlObj, NULL);
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
static void* link_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
static void* link_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
- ret_if(!data || !xmlObj);
+ retv_if(!data || !xmlObj, NULL);
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
static void* launch_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
static void* launch_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
- ret_if(!data || !xmlObj);
+ retv_if(!data || !xmlObj, NULL);
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
static void* slider_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
static void* slider_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
- ret_if(!data || !xmlObj);
+ retv_if(!data || !xmlObj, NULL);
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
static void* checkbox_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
static void* checkbox_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
- ret_if(!data || !xmlObj);
+ retv_if(!data || !xmlObj, NULL);
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
Setting_GenGroupItem_Data *list_item = data;
xmlNode* xmlObj = list_item->userdata;
Setting_GenGroupItem_Data *list_item = data;
xmlNode* xmlObj = list_item->userdata;
+ if(!xmlObj) {
+ FREE(entry_str_utf8);
+ return;
+ }
+
xmlAttrPtr newattr;
const char *title = (char*)xmlSetProp(xmlObj, "value",entry_str_utf8);
xmlAttrPtr newattr;
const char *title = (char*)xmlSetProp(xmlObj, "value",entry_str_utf8);
static void* editbox_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
static void* editbox_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
- ret_if(!data || !xmlObj);
+ retv_if(!data || !xmlObj, NULL);
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
//char *value = (char*)xmlGetProp(xmlObj, "string");
char *value = (char*)xmlGetProp(xmlObj, "value");
SETTING_TRACE(">>> value = %s", value);
//char *value = (char*)xmlGetProp(xmlObj, "string");
char *value = (char*)xmlGetProp(xmlObj, "value");
SETTING_TRACE(">>> value = %s", value);
Evas_Object *rgd = NULL;
if (xmlObj->children && !data_parentItem->rgd) {//to protect from entering repeatly
Evas_Object *rgd = NULL;
if (xmlObj->children && !data_parentItem->rgd) {//to protect from entering repeatly
rgd = elm_radio_add(scroller);
elm_radio_value_set(rgd, -1);
rgd = elm_radio_add(scroller);
elm_radio_value_set(rgd, -1);
char *type;
char *subitem_title = NULL;
int subitem_index = 0;
char *type;
char *subitem_title = NULL;
int subitem_index = 0;
} else {
SETTING_TRACE("invalid type[:%s]", type);
}
} else {
SETTING_TRACE("invalid type[:%s]", type);
}
static void* setting_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
static void* setting_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
- ret_if(!data || !xmlObj);
+ retv_if(!data || !xmlObj, NULL);
#if 1
PluginNode* node = (PluginNode*)data;
#if 1
PluginNode* node = (PluginNode*)data;
static void* expandlist_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
static void* expandlist_func(void *data, xmlNode *xmlObj)
{
SETTING_TRACE_BEGIN;
- ret_if(!data || !xmlObj);
+ retv_if(!data || !xmlObj, NULL);
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
PluginNode* node = (PluginNode*)data;
Draw_Data *pd = node->pd;
PluginNode *node = calloc(1, sizeof(PluginNode));
Draw_Data *pd = calloc(1, sizeof(Draw_Data));
PluginNode *node = calloc(1, sizeof(PluginNode));
Draw_Data *pd = calloc(1, sizeof(Draw_Data));
+
+ if (node && !pd) {
+ free(node);
+ node = NULL;
+ }
+
setting_retvm_if(!pd, -1, "Create Draw_Data obj failed");
//eina_init();
setting_retvm_if(!pd, -1, "Create Draw_Data obj failed");
//eina_init();