Fix exception handling of watch_time_get_dst_status API 97/129997/1
authorHwankyu Jhun <h.jhun@samsung.com>
Fri, 19 May 2017 00:11:05 +0000 (09:11 +0900)
committerHwankyu Jhun <h.jhun@samsung.com>
Fri, 19 May 2017 00:12:50 +0000 (09:12 +0900)
The watch_time_get_dst_status API should check whether the parameter
is NULL pointer or NOT.

Change-Id: I5194f58ee841ef263fceb7e694011329a495e655
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
src/watch_app_main.c

index 1bade82..e11c5ee 100755 (executable)
@@ -972,7 +972,7 @@ EXPORT_API int watch_time_get_time_zone(watch_time_h watch_time,
 
 EXPORT_API int watch_time_get_dst_status(watch_time_h watch_time, bool *status)
 {
-       if (watch_time == NULL)
+       if (watch_time == NULL || status == NULL)
                return watch_app_error(APP_ERROR_INVALID_PARAMETER, __FUNCTION__, NULL);
 
        if (watch_time->indaylight)