From 5e0bb60e2a87fa69407a768ffa2a1a2fa59d05b2 Mon Sep 17 00:00:00 2001 From: SaidiReddy Yenuga Date: Thu, 15 Dec 2016 18:55:04 +0530 Subject: qcacld-3.0: Remove NULL check in get Tx power API Adapter can be NULL and accessing it result in crash Remove NULL check for adapter to avoid crash CRs-Fixed: 1094603 Change-Id: I1c7efdfeb7829640cef740f873cb367befd810c9 --- core/hdd/src/wlan_hdd_power.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/core/hdd/src/wlan_hdd_power.c b/core/hdd/src/wlan_hdd_power.c index 6bf454143459..9576503586c3 100644 --- a/core/hdd/src/wlan_hdd_power.c +++ b/core/hdd/src/wlan_hdd_power.c @@ -2357,11 +2357,6 @@ static int __wlan_hdd_cfg80211_get_txpower(struct wiphy *wiphy, return status; } - if (!adapter) { - hdd_err("adapter is NULL"); - return -ENOENT; - } - /* Validate adapter sessionId */ if (wlan_hdd_validate_session_id(adapter->sessionId)) { hdd_err("invalid session id: %d", adapter->sessionId); -- cgit v1.2.3