[Prevent] Ensure pointer is not NULL before it's referenced.
authorJan Olszak <j.olszak@samsung.com>
Fri, 7 Dec 2012 07:56:35 +0000 (08:56 +0100)
committerJan Olszak <j.olszak@samsung.com>
Wed, 12 Dec 2012 08:57:38 +0000 (09:57 +0100)
[Issue#] ace_param_list->items could have been NULL when referenced
[Bug] N/A
[Cause] N/A
[Solution] Small change in conditions check.
[Verification] Build plugins. Run plugin-common tests.

Change-Id: I0b0ace5e95615311680fc29de6a421f56f7f0b9b

src/wrt-popup/ace/popup-bin/Popup.cpp

index 9799f51..abc614f 100644 (file)
@@ -158,7 +158,7 @@ static int _ace_params_deserializer(ace_param_list_t* ace_param_list, Wrt::Popup
 }
 
 static void _ace_params_finalize(ace_param_list_t* ace_param_list) {
-    if (NULL == ace_param_list || ace_param_list->items) {
+    if (!ace_param_list || !ace_param_list->items) {
         LogDebug("List is null, nothing to do");
         return;
     }