From: JunsuChoi Date: Fri, 30 Dec 2016 06:32:11 +0000 (+0900) Subject: Add null check for when get window angle X-Git-Tag: accepted/tizen/common/20170118.173957~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bbf7bc4b76763fe7223107d5f6af3ca8f58ea400;p=platform%2Fcore%2Fuifw%2Fe-mod-tizen-screen-reader.git Add null check for when get window angle add null check before using e_zone_current_get's result variable. when get window angle Change-Id: Ief734dfb94e74c0e7e535b69ea0014e0431e470f --- diff --git a/src/e_screen_reader_gestures.c b/src/e_screen_reader_gestures.c index 9389380..6d912ac 100644 --- a/src/e_screen_reader_gestures.c +++ b/src/e_screen_reader_gestures.c @@ -187,12 +187,17 @@ int __get_window_angle(void) E_Comp_Wl_Client_Data *cdata; zone = e_zone_current_get(); + if(!zone) + { + DEBUG("Fail to found zone"); + return cover->angle; + } E_CLIENT_REVERSE_FOREACH(ec) { if (e_object_is_del(E_OBJECT(ec))) continue; if (e_client_util_ignored_get(ec)) continue; - if (zone && ec->zone != zone) continue; + if (ec->zone != zone) continue; if (!ec->frame) continue; cdata = (E_Comp_Wl_Client_Data *)ec->comp_data; if (cdata && cdata->sub.data) continue;