diff options
author | Saurabh Srivastava <ssrivast@codeaurora.org> | 2018-11-16 11:49:40 +0530 |
---|---|---|
committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2018-11-15 22:33:51 -0800 |
commit | b00c1c26c9d7673c8bc84d7e8697958541912587 (patch) | |
tree | bd25a25816885539720ea9f626de77f75de47f67 /gnss | |
parent | 0056afe9bd404cd3ff081d5cc9e4a5f4d77309fd (diff) | |
download | gps-b00c1c26c9d7673c8bc84d7e8697958541912587.tar.gz |
Invoking dlclose in error case
Invoking dlclose for loc_net_iface
library dlopen call in error case.
Change-Id: Ib8d4b05904214ebaa83608309679bc055bd7abe5
CRs-Fixed: 2347372
Diffstat (limited to 'gnss')
-rw-r--r-- | gnss/GnssAdapter.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gnss/GnssAdapter.cpp b/gnss/GnssAdapter.cpp index b7c57e8..fc59c22 100644 --- a/gnss/GnssAdapter.cpp +++ b/gnss/GnssAdapter.cpp @@ -3716,6 +3716,7 @@ void GnssAdapter::initDefaultAgps() { dlsym(handle, "LocNetIfaceAgps_getAgpsCbInfo"); if (getAgpsCbInfo == nullptr) { LOC_LOGE("%s]: Failed to get method LocNetIfaceAgps_getStatusCb", __func__); + dlclose(handle); return; } @@ -3723,6 +3724,7 @@ void GnssAdapter::initDefaultAgps() { if (cbInfo.statusV4Cb == nullptr) { LOC_LOGE("%s]: statusV4Cb is nullptr!", __func__); + dlclose(handle); return; } |