summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lib/eo/eo.c12
-rw-r--r--src/tests/eo/suite/eo_test_reflection.c2
2 files changed, 8 insertions, 6 deletions
diff --git a/src/lib/eo/eo.c b/src/lib/eo/eo.c
index efd68055dc..a5c72e0762 100644
--- a/src/lib/eo/eo.c
+++ b/src/lib/eo/eo.c
@@ -3660,16 +3660,18 @@ efl_property_reflection_set(Eo *obj_id, const char *property_name, Eina_Value va
3660EAPI Eina_Value 3660EAPI Eina_Value
3661efl_property_reflection_get(Eo *obj_id, const char *property_name) 3661efl_property_reflection_get(Eo *obj_id, const char *property_name)
3662{ 3662{
3663 EO_OBJ_POINTER(obj_id, obj); 3663 Eina_Value r = eina_value_error_init(EINA_ERROR_NOT_IMPLEMENTED);
3664
3665 EO_OBJ_POINTER_GOTO(obj_id, obj, end);
3664 const Efl_Object_Property_Reflection *reflection = _efl_class_reflection_find(obj->klass, property_name); 3666 const Efl_Object_Property_Reflection *reflection = _efl_class_reflection_find(obj->klass, property_name);
3665 3667
3666 if (!reflection || !reflection->get) goto end; 3668 if (reflection && reflection->get)
3669 r = reflection->get(obj_id);
3667 3670
3668 return reflection->get(obj_id); 3671 end:
3669end:
3670 EO_OBJ_DONE(obj_id); 3672 EO_OBJ_DONE(obj_id);
3671 3673
3672 return EINA_VALUE_EMPTY; 3674 return r;
3673} 3675}
3674 3676
3675EAPI Efl_Class_Type 3677EAPI Efl_Class_Type
diff --git a/src/tests/eo/suite/eo_test_reflection.c b/src/tests/eo/suite/eo_test_reflection.c
index b517f61ad5..2546cfefed 100644
--- a/src/tests/eo/suite/eo_test_reflection.c
+++ b/src/tests/eo/suite/eo_test_reflection.c
@@ -17,7 +17,7 @@ EFL_START_TEST(eo_test_reflection_invalid)
17 17
18 simple_a_set(simple, 22); 18 simple_a_set(simple, 22);
19 efl_property_reflection_set(simple, "simple_a_asdf", numb_val); 19 efl_property_reflection_set(simple, "simple_a_asdf", numb_val);
20 fail_if(efl_property_reflection_get(simple, "simple_a_invalid").type != EINA_VALUE_EMPTY.type); 20 fail_if(efl_property_reflection_get(simple, "simple_a_invalid").type != EINA_VALUE_TYPE_ERROR);
21} 21}
22EFL_END_TEST 22EFL_END_TEST
23 23