[elm_index] bug fix: eina_list null check
authorJaeun Choi <jaeun12.choi@samsung.com>
Thu, 14 Mar 2013 13:03:17 +0000 (22:03 +0900)
committerSungho Kwak <sungho1.kwak@samsung.com>
Mon, 18 Mar 2013 04:21:28 +0000 (13:21 +0900)
src/lib/elm_index.c

index c32c2e3..720fe8f 100644 (file)
@@ -313,8 +313,11 @@ _index_box_auto_fill(Evas_Object *obj,
      }
 
    // TIZEN ONLY adjust the last item's theme according to winset gui
-   it = eina_list_nth(sd->items, i - 1);
-   edje_object_signal_emit(VIEW(it), "elm,last,item", "elm");
+   if (sd->items)
+     {
+        it = eina_list_nth(sd->items, i - 1);
+        edje_object_signal_emit(VIEW(it), "elm,last,item", "elm");
+     }
    // TIZEN ONLY
 
    evas_object_smart_calculate(box);