Fix Coverity Scan CID 21666 (Variable measResultListEUTRA2 going out of scope leaks the storage it points to.)
This commit is contained in:
@@ -4231,9 +4231,14 @@ uint8_t do_MeasurementReport(uint8_t Mod_id, uint8_t *buffer,int measid,int phy_
|
||||
if(enc_rval.encoded == -1) {
|
||||
LOG_I(RRC, "[eNB AssertFatal]ASN1 message encoding failed (%s, %lu)!\n",
|
||||
enc_rval.failed_type->name, enc_rval.encoded);
|
||||
free(measResultListEUTRA2);
|
||||
measResultListEUTRA2 = NULL;
|
||||
return -1;
|
||||
}
|
||||
|
||||
free(measResultListEUTRA2);
|
||||
measResultListEUTRA2 = NULL;
|
||||
|
||||
return((enc_rval.encoded+7)/8);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user