mirror of
https://github.com/team-infusion-developers/android_hardware_samsung.git
synced 2024-11-06 21:55:41 +00:00
libril: Fix freeing of strings for roaming protocol flag
Change-Id: Id6150885203a64733bffeb7ce6dc4e91fab305df
This commit is contained in:
parent
e483571e5d
commit
7240949c54
1 changed files with 6 additions and 1 deletions
|
@ -1943,7 +1943,7 @@ Return<void> RadioImpl::setInitialAttachApn(int32_t serial, const DataProfileInf
|
|||
|
||||
#ifdef NEEDS_ROAMING_PROTOCOL_FIELD
|
||||
if (!copyHidlStringToRil(&iaa.roamingProtocol, dataProfileInfo.roamingProtocol, pRI)) {
|
||||
memsetAndFreeStrings(4, iaa.apn, iaa.protocol, iaa.username, iaa.roamingProtocol);
|
||||
memsetAndFreeStrings(4, iaa.apn, iaa.protocol, iaa.username, iaa.password);
|
||||
return Void();
|
||||
}
|
||||
#endif
|
||||
|
@ -1954,7 +1954,12 @@ Return<void> RadioImpl::setInitialAttachApn(int32_t serial, const DataProfileInf
|
|||
|
||||
CALL_ONREQUEST(RIL_REQUEST_SET_INITIAL_ATTACH_APN, &iaa, sizeof(iaa), pRI, mSlotId);
|
||||
|
||||
#ifdef NEEDS_ROAMING_PROTOCOL_FIELD
|
||||
memsetAndFreeStrings(5, iaa.apn, iaa.protocol, iaa.username, iaa.password,
|
||||
iaa.roamingProtocol);
|
||||
#else
|
||||
memsetAndFreeStrings(4, iaa.apn, iaa.protocol, iaa.username, iaa.password);
|
||||
#endif
|
||||
} else {
|
||||
RIL_InitialAttachApn_v15 iaa = {};
|
||||
|
||||
|
|
Loading…
Reference in a new issue