add null check in ug_disable_effect 71/73471/2 accepted/tizen/common/20160610.175824 accepted/tizen/ivi/20160609.090150 accepted/tizen/mobile/20160609.090120 accepted/tizen/tv/20160609.090223 accepted/tizen/wearable/20160609.090138 submit/tizen/20160608.045259
authorJiwoong Im <jiwoong.im@samsung.com>
Wed, 8 Jun 2016 08:22:06 +0000 (17:22 +0900)
committerJiwoong Im <jiwoong.im@samsung.com>
Wed, 8 Jun 2016 08:24:08 +0000 (17:24 +0900)
Change-Id: I468e972f1fd82f2055656f0496e65d29b5d6c346
Signed-off-by: Jiwoong Im <jiwoong.im@samsung.com>
src/ug.c

index 2090c58f85aa9a7ee3ff03210a18ce0ba2422448..2f0c5a6f787905e608f5ffdbcf5f760198f8f9de 100644 (file)
--- a/src/ug.c
+++ b/src/ug.c
@@ -357,6 +357,10 @@ UG_API int ug_send_message(ui_gadget_h ug, app_control_h msg)
 
 UG_API int ug_disable_effect(ui_gadget_h ug)
 {
+       if (!ug) {
+               _ERR("ug input param is null");
+               return -1;
+       }
        if (ug->layout_state != UG_LAYOUT_INIT) {
                _ERR("ug_disable_effect() failed: ug has already been shown");
                return -1;