forked from enlightenment/efl
parent
e27e139ac8
commit
d4b0093826
|
@ -432,7 +432,7 @@ efreet_ini_double_set(Efreet_Ini *ini, const char *key, double value)
|
|||
snprintf(str, 512, "%.6f", value);
|
||||
len = strlen(str) - 1;
|
||||
/* Strip trailing zero's */
|
||||
while (str[len] == '0' && str[len - 1] != '.') str[len--] = 0;
|
||||
while (str[len] == '0' && str[len - 1] != '.') str[len--] = '\0';
|
||||
efreet_ini_string_set(ini, key, str);
|
||||
}
|
||||
|
||||
|
|
|
@ -3104,7 +3104,7 @@ efreet_menu_path_set(Efreet_Menu_Internal *internal, const char *path)
|
|||
p = strrchr(tmp, '/');
|
||||
if (p)
|
||||
{
|
||||
*p = 0;
|
||||
*p = '\0';
|
||||
p++;
|
||||
|
||||
internal->file.path = strdup(tmp);
|
||||
|
@ -3288,7 +3288,7 @@ efreet_menu_path_get(Efreet_Menu_Internal *internal, const char *suffix)
|
|||
}
|
||||
|
||||
len = strlen(path);
|
||||
while (path[len] == '/') path[len--] = 0;
|
||||
while (path[len] == '/') path[len--] = '\0';
|
||||
|
||||
return strdup(path);
|
||||
}
|
||||
|
|
|
@ -679,9 +679,9 @@ efreet_util_glob_match(const char *str, const char *glob)
|
|||
{
|
||||
if (!str || !glob)
|
||||
return 0;
|
||||
if (glob[0] == 0)
|
||||
if (glob[0] == '\0')
|
||||
{
|
||||
if (str[0] == 0) return 1;
|
||||
if (str[0] == '\0') return 1;
|
||||
return 0;
|
||||
}
|
||||
if (!strcmp(glob, "*")) return 1;
|
||||
|
|
|
@ -290,7 +290,7 @@ efreet_xml_tag_parse(char **data, int *size, const char **tag)
|
|||
|
||||
if (buf_size > 256) buf_size = 256;
|
||||
memcpy(buf, start, buf_size - 1);
|
||||
buf[buf_size - 1] = 0;
|
||||
buf[buf_size - 1] = '\0';
|
||||
*tag = ecore_string_instance(buf);
|
||||
|
||||
return 1;
|
||||
|
@ -338,7 +338,7 @@ efreet_xml_attributes_parse(char **data, int *size,
|
|||
|
||||
if (buf_size > 256) buf_size = 256;
|
||||
memcpy(buf, start, buf_size - 1);
|
||||
buf[buf_size - 1] = 0;
|
||||
buf[buf_size - 1] = '\0';
|
||||
attr[count].key = ecore_string_instance(buf);
|
||||
|
||||
/* search for '=', key/value seperator */
|
||||
|
@ -412,7 +412,7 @@ efreet_xml_attributes_parse(char **data, int *size,
|
|||
|
||||
if (buf_size > 256) buf_size = 256;
|
||||
memcpy(buf, start, buf_size - 1);
|
||||
buf[buf_size - 1] = 0;
|
||||
buf[buf_size - 1] = '\0';
|
||||
attr[count].value = ecore_string_instance(buf);
|
||||
|
||||
count++;
|
||||
|
@ -484,7 +484,7 @@ efreet_xml_text_parse(char **data, int *size, char **text)
|
|||
|
||||
*text = malloc(buf_size);
|
||||
memcpy(*text, start, buf_size - 1);
|
||||
(*text)[buf_size - 1] = 0;
|
||||
(*text)[buf_size - 1] = '\0';
|
||||
}
|
||||
|
||||
static int
|
||||
|
|
Loading…
Reference in New Issue