summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lib/eina/eina_array.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/lib/eina/eina_array.c b/src/lib/eina/eina_array.c
index 99891adcc5..e439450021 100644
--- a/src/lib/eina/eina_array.c
+++ b/src/lib/eina/eina_array.c
@@ -173,17 +173,16 @@ eina_array_accessor_free(Eina_Accessor_Array *it)
173} 173}
174 174
175static Eina_Accessor * 175static Eina_Accessor *
176eina_array_accessor_clone(const Eina_Array *array) 176eina_array_accessor_clone(const Eina_Accessor_Array *it)
177{ 177{
178 Eina_Accessor_Array *ac; 178 Eina_Accessor_Array *ac;
179 179
180 EINA_SAFETY_ON_NULL_RETURN_VAL(array, NULL); 180 EINA_MAGIC_CHECK_ARRAY_ACCESSOR(it, NULL);
181 EINA_MAGIC_CHECK_ARRAY(array);
182 181
183 ac = calloc(1, sizeof (Eina_Accessor_Array)); 182 ac = calloc(1, sizeof (Eina_Accessor_Array));
184 if (!ac) return NULL; 183 if (!ac) return NULL;
185 184
186 memcpy(ac, array, sizeof(Eina_Accessor_Array)); 185 memcpy(ac, it, sizeof(Eina_Accessor_Array));
187 186
188 return &ac->accessor; 187 return &ac->accessor;
189} 188}