Fix crash in AgpsManager when accessing invalid pointer

Crash was happening because a local structure was being
passed over by reference to the MsgTask, as a result
data was being read and saved from the reference when
the local structure was already out of scope.

CRs-Fixed: 2124083

Change-Id: Ifb24652d5b665a47b8ae88f43dd86876274a28cf
This commit is contained in:
Bhavna Sharma 2017-10-09 11:42:11 -07:00
parent 39526894cf
commit de6898af20

View file

@ -2554,7 +2554,7 @@ void GnssAdapter::initAgpsCommand(const AgpsCbInfo& cbInfo){
/* Message to initialize AGPS module */
struct AgpsMsgInit: public LocMsg {
const AgpsCbInfo& mCbInfo;
const AgpsCbInfo mCbInfo;
GnssAdapter& mAdapter;
inline AgpsMsgInit(const AgpsCbInfo& cbInfo,