aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/evas/canvas/evas_smart.c
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2017-07-12 17:19:28 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2017-07-12 17:38:51 +0900
commit9513fed85ea00637745362a5a34083da3d230f22 (patch)
tree013425bd1b6149b10211d33a765f6df2acbe93b7 /src/lib/evas/canvas/evas_smart.c
parentpo files - update lines/comments (diff)
downloadefl-9513fed85ea00637745362a5a34083da3d230f22.tar.gz
evas_smart: Fix evas_smart_callback_description_find
bsearch was returnign a cb** not a cb* Fixes https://phab.enlightenment.org/T4540
Diffstat (limited to 'src/lib/evas/canvas/evas_smart.c')
-rw-r--r--src/lib/evas/canvas/evas_smart.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/lib/evas/canvas/evas_smart.c b/src/lib/evas/canvas/evas_smart.c
index ccd9a69855..a070c98a95 100644
--- a/src/lib/evas/canvas/evas_smart.c
+++ b/src/lib/evas/canvas/evas_smart.c
@@ -326,7 +326,11 @@ _evas_smart_cb_description_cmp_search(const void *p1, const void *p2)
const Evas_Smart_Cb_Description *
evas_smart_cb_description_find(const Evas_Smart_Cb_Description_Array *a, const char *name)
{
+ const Evas_Smart_Cb_Description **found = NULL;
+
if (!a->array) return NULL;
- return bsearch(name, a->array, a->size, sizeof(Evas_Smart_Cb_Description *),
- _evas_smart_cb_description_cmp_search);
+ found = bsearch(name, a->array, a->size, sizeof(Evas_Smart_Cb_Description *),
+ _evas_smart_cb_description_cmp_search);
+
+ return found ? (*found) : NULL;
}