summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSunmeet Gill <sgill@codeaurora.org>2017-10-25 10:50:38 -0700
committerJayachandran Chinnakkannu <jayachandranc@google.com>2017-12-13 19:28:44 +0000
commitb5145a4ef609a462a48e05640d0998271f48edf6 (patch)
tree8a1b16b281347d43cc2e46aca6cbba1b0978bebc
parentfbc8aaa3bf56d3be40d12bb4cf97540bc9dc6697 (diff)
downloadipacfg-mgr-b5145a4ef609a462a48e05640d0998271f48edf6.tar.gz
IPACM: fix the ipacm crash issue on SSR
On SSR scenario without tethering enable once, ipacm crash due to uninitialized pointer, elrInstance. Make the change to initialize it as NULL Test: Verified force modem SSR and ipacm didn't crash Verified basic data and tethering use cases Bug: 67019241 CRs-Fixed: 2132095 Change-Id: I126f44c02a8b186dd2e61392cb2d9732263165e1
-rw-r--r--msm8998/ipacm/src/IPACM_Main.cpp3
-rw-r--r--msm8998/ipacm/src/IPACM_OffloadManager.cpp2
2 files changed, 5 insertions, 0 deletions
diff --git a/msm8998/ipacm/src/IPACM_Main.cpp b/msm8998/ipacm/src/IPACM_Main.cpp
index 13cdb51..62dc596 100644
--- a/msm8998/ipacm/src/IPACM_Main.cpp
+++ b/msm8998/ipacm/src/IPACM_Main.cpp
@@ -694,6 +694,7 @@ void* ipa_driver_msg_notifier(void *param)
if (OffloadMng->elrInstance == NULL) {
IPACMERR("OffloadMng->elrInstance is NULL, can't forward to framework!\n");
} else {
+ IPACMERR("calling OffloadMng->elrInstance->onLimitReached \n");
OffloadMng->elrInstance->onLimitReached();
}
continue;
@@ -703,6 +704,7 @@ void* ipa_driver_msg_notifier(void *param)
if (OffloadMng->elrInstance == NULL) {
IPACMERR("OffloadMng->elrInstance is NULL, can't forward to framework!\n");
} else {
+ IPACMERR("calling OffloadMng->elrInstance->onOffloadStopped \n");
OffloadMng->elrInstance->onOffloadStopped(IpaEventRelay::ERROR);
}
continue;
@@ -712,6 +714,7 @@ void* ipa_driver_msg_notifier(void *param)
if (OffloadMng->elrInstance == NULL) {
IPACMERR("OffloadMng->elrInstance is NULL, can't forward to framework!\n");
} else {
+ IPACMERR("calling OffloadMng->elrInstance->onOffloadSupportAvailable \n");
OffloadMng->elrInstance->onOffloadSupportAvailable();
}
continue;
diff --git a/msm8998/ipacm/src/IPACM_OffloadManager.cpp b/msm8998/ipacm/src/IPACM_OffloadManager.cpp
index 2061fd2..4010e72 100644
--- a/msm8998/ipacm/src/IPACM_OffloadManager.cpp
+++ b/msm8998/ipacm/src/IPACM_OffloadManager.cpp
@@ -59,6 +59,8 @@ IPACM_OffloadManager::IPACM_OffloadManager()
upstream_v6_up = false;
memset(event_cache, 0, MAX_EVENT_CACHE*sizeof(framework_event_cache));
latest_cache_index = 0;
+ elrInstance = NULL;
+ touInstance = NULL;
return ;
}