summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lib/ecore/ecore_internal.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/lib/ecore/ecore_internal.h b/src/lib/ecore/ecore_internal.h
index c585f40aa4..8a54487aba 100644
--- a/src/lib/ecore/ecore_internal.h
+++ b/src/lib/ecore/ecore_internal.h
@@ -40,7 +40,10 @@ efl_model_list_value_get(Eina_List *childrens,
40 Eina_List *l; 40 Eina_List *l;
41 Eo *child; 41 Eo *child;
42 42
43 eina_value_array_setup(&v, EINA_VALUE_TYPE_OBJECT, eina_list_count(childrens)); 43 if (eina_list_count(childrens) < start + count)
44 return eina_value_error_init(EFL_MODEL_ERROR_INCORRECT_VALUE);
45
46 eina_value_array_setup(&v, EINA_VALUE_TYPE_OBJECT, 4);
44 47
45 childrens = eina_list_nth_list(childrens, start); 48 childrens = eina_list_nth_list(childrens, start);
46 49