[access] _elm_access_add() could return NULL
authorShinwoo Kim <kimcinoo.efl@gmail.com>
Mon, 7 Jan 2013 05:56:51 +0000 (05:56 +0000)
committerShinwoo Kim <kimcinoo.efl@gmail.com>
Mon, 7 Jan 2013 05:56:51 +0000 (05:56 +0000)
SVN revision: 82319

legacy/elementary/src/lib/elm_access.c

index a3eb798..dc4f0f0 100644 (file)
@@ -558,6 +558,8 @@ _elm_access_edje_object_part_object_register(Evas_Object* obj,
 
    // create access object
    ao = _elm_access_add(obj);
+   if (!ao) return;
+
    evas_object_event_callback_add(po, EVAS_CALLBACK_RESIZE,
                                   _content_resize, ao);
    evas_object_event_callback_add(po, EVAS_CALLBACK_MOVE,
@@ -693,6 +695,8 @@ _elm_access_widget_item_register(Elm_Widget_Item *item)
    // create access object
    ho = item->view;
    ao = _elm_access_add(item->widget);
+   if (!ao) return;
+
    evas_object_event_callback_add(ho, EVAS_CALLBACK_RESIZE,
                                   _content_resize, ao);
    evas_object_event_callback_add(ho, EVAS_CALLBACK_MOVE,