Wifi-HAL: Fix null check while setting on_alert handler

While setting on_alert handler, check should be for non-null
handler but not null handler.

Change-Id: I1823e72cf6d05779f1cfd018fdb5c69a5f570187
diff --git a/qcwcn/wifi_hal/wifilogger.cpp b/qcwcn/wifi_hal/wifilogger.cpp
index 17c4b0c..757e62e 100644
--- a/qcwcn/wifi_hal/wifilogger.cpp
+++ b/qcwcn/wifi_hal/wifilogger.cpp
@@ -548,7 +548,7 @@
 
     info->on_ring_buffer_data = handler.on_ring_buffer_data;
     if (handler.on_ring_buffer_data == NULL) {
-        ALOGE("Input handler is NULL");
+        ALOGE("Set log handler is NULL");
         return WIFI_ERROR_UNKNOWN;
     }
     return WIFI_SUCCESS;
@@ -572,8 +572,8 @@
     wifi_handle wifiHandle = getWifiHandle(iface);
     hal_info *info = getHalInfo(wifiHandle);
 
-    if (handler.on_alert) {
-        ALOGE("Input handler is NULL");
+    if (handler.on_alert == NULL) {
+        ALOGE("Set alert handler is NULL");
         return WIFI_ERROR_UNKNOWN;
     }
     //TODO check locking