forked from enlightenment/efl
efreet - fix recusrion checks need to pop as well as push.
stable release - cherry-pick me! this fixes a lack of popping the efret recursion stack handler. this wasn't done in 1.8 and is a bug.
This commit is contained in:
parent
749d5d7b50
commit
931d02378b
|
@ -153,7 +153,11 @@ cache_scan(Eina_Inarray *stack, const char *path, const char *base_id,
|
|||
eina_inarray_push(stack, &st);
|
||||
|
||||
it = eina_file_stat_ls(path);
|
||||
if (!it) return 1;
|
||||
if (!it)
|
||||
{
|
||||
eina_inarray_pop(stack);
|
||||
return 1;
|
||||
}
|
||||
id[0] = '\0';
|
||||
EINA_ITERATOR_FOREACH(it, info)
|
||||
{
|
||||
|
@ -182,11 +186,13 @@ cache_scan(Eina_Inarray *stack, const char *path, const char *base_id,
|
|||
if (!cache_add(info->path, file_id, priority, changed))
|
||||
{
|
||||
eina_iterator_free(it);
|
||||
eina_inarray_pop(stack);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
eina_iterator_free(it);
|
||||
eina_inarray_pop(stack);
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
|
|
@ -284,7 +284,7 @@ icon_changes_listen_recursive(Eina_Inarray *stack, const char *path, Eina_Bool b
|
|||
}
|
||||
if (ecore_file_is_dir(path)) icon_changes_monitor_add(path);
|
||||
it = eina_file_stat_ls(path);
|
||||
if (!it) return;
|
||||
if (!it) goto end;
|
||||
EINA_ITERATOR_FOREACH(it, info)
|
||||
{
|
||||
if (info->path[info->name_start] == '.') continue;
|
||||
|
@ -293,6 +293,8 @@ icon_changes_listen_recursive(Eina_Inarray *stack, const char *path, Eina_Bool b
|
|||
icon_changes_listen_recursive(stack, info->path, EINA_FALSE);
|
||||
}
|
||||
eina_iterator_free(it);
|
||||
end:
|
||||
eina_inarray_pop(stack);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -319,7 +321,7 @@ desktop_changes_listen_recursive(Eina_Inarray *stack, const char *path, Eina_Boo
|
|||
}
|
||||
if (ecore_file_is_dir(path)) desktop_changes_monitor_add(path);
|
||||
it = eina_file_stat_ls(path);
|
||||
if (!it) return;
|
||||
if (!it) goto end;
|
||||
EINA_ITERATOR_FOREACH(it, info)
|
||||
{
|
||||
if (info->path[info->name_start] == '.') continue;
|
||||
|
@ -328,6 +330,8 @@ desktop_changes_listen_recursive(Eina_Inarray *stack, const char *path, Eina_Boo
|
|||
desktop_changes_listen_recursive(stack, info->path, EINA_FALSE);
|
||||
}
|
||||
eina_iterator_free(it);
|
||||
end:
|
||||
eina_inarray_pop(stack);
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in New Issue