|
|
|
@ -663,6 +663,8 @@ int yon_config_append_element(char *key, char *append, char *divider){
|
|
|
|
char *temp = yon_char_append_element((char*)dict->data,append,divider);
|
|
|
|
char *temp = yon_char_append_element((char*)dict->data,append,divider);
|
|
|
|
if (!yon_char_is_empty((char*)dict->data)) free(dict->data);
|
|
|
|
if (!yon_char_is_empty((char*)dict->data)) free(dict->data);
|
|
|
|
dict->data = temp;
|
|
|
|
dict->data = temp;
|
|
|
|
|
|
|
|
dict->flag1 = 1;
|
|
|
|
|
|
|
|
yon_config_remove_ignore(key);
|
|
|
|
return 1;
|
|
|
|
return 1;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@ -830,21 +832,6 @@ int yon_config_set(char *key, void *data){
|
|
|
|
} else return 0;
|
|
|
|
} else return 0;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
int yon_config_append(char *key, char *data, char *divider){
|
|
|
|
|
|
|
|
check_config{
|
|
|
|
|
|
|
|
yon_config_parameter *dict = (yon_config_parameter*)yon_dictionary_get((dictionary**)&__yon__config__strings,key);
|
|
|
|
|
|
|
|
if (dict){
|
|
|
|
|
|
|
|
if (strcmp(((char*)dict->data),"")!=0){
|
|
|
|
|
|
|
|
char *str = (char*)dict->data;
|
|
|
|
|
|
|
|
dict->data=(void*)(yon_char_unite(yon_char_is_empty(str)?"":str,yon_char_is_empty(str)?"":divider,data,NULL));
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
else dict->data=(void*)yon_char_new(data);
|
|
|
|
|
|
|
|
dict->flag1=1;
|
|
|
|
|
|
|
|
return 1;
|
|
|
|
|
|
|
|
} else return 0;
|
|
|
|
|
|
|
|
} else return 0;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
int yon_config_clean(){
|
|
|
|
int yon_config_clean(){
|
|
|
|
check_config{
|
|
|
|
check_config{
|
|
|
|
__yon__config__strings = (yon_config_parameter*)yon_dictionary_free_all((dictionary*)__yon__config__strings, NULL);
|
|
|
|
__yon__config__strings = (yon_config_parameter*)yon_dictionary_free_all((dictionary*)__yon__config__strings, NULL);
|
|
|
|
|