Commit ab4a1806 authored by masayuki.harada's avatar masayuki.harada Committed by Haruki NAOI

Fix: Memory leak.

(cherry picked from commit 7013d216db25347d89d6152f37aea5333f72c372)
parent f5433cb0
...@@ -647,6 +647,7 @@ rlc_op_status_t rrc_rlc_remove_rlc ( ...@@ -647,6 +647,7 @@ rlc_op_status_t rrc_rlc_remove_rlc (
rb_idP, lcid, rb_idP, lcid,
(srb_flagP) ? "SRB" : "DRB"); (srb_flagP) ? "SRB" : "DRB");
} }
free(rlc_union_p);
return RLC_OP_STATUS_OK; return RLC_OP_STATUS_OK;
} }
......
...@@ -2881,7 +2881,6 @@ do_RRCConnectionSetup( ...@@ -2881,7 +2881,6 @@ do_RRCConnectionSetup(
else else
physicalConfigDedicated2->soundingRS_UL_ConfigDedicated = NULL; physicalConfigDedicated2->soundingRS_UL_ConfigDedicated = NULL;
physicalConfigDedicated2->antennaInfo = CALLOC(1,sizeof(*physicalConfigDedicated2->antennaInfo));
physicalConfigDedicated2->schedulingRequestConfig = CALLOC(1,sizeof(*physicalConfigDedicated2->schedulingRequestConfig)); physicalConfigDedicated2->schedulingRequestConfig = CALLOC(1,sizeof(*physicalConfigDedicated2->schedulingRequestConfig));
// PDSCH // PDSCH
...@@ -3202,6 +3201,11 @@ do_RRCConnectionSetup( ...@@ -3202,6 +3201,11 @@ do_RRCConnectionSetup(
LOG_D(RRC,"RRCConnectionSetup Encoded %zd bits (%zd bytes) \n", LOG_D(RRC,"RRCConnectionSetup Encoded %zd bits (%zd bytes) \n",
enc_rval.encoded,(enc_rval.encoded+7)/8); enc_rval.encoded,(enc_rval.encoded+7)/8);
free(mac_MainConfig->phr_Config);
free(maxHARQ_Tx);
free(periodicBSR_Timer);
free(mac_MainConfig->ul_SCH_Config);
free(rrcConnectionSetup->criticalExtensions.choice.c1.choice.rrcConnectionSetup_r8.radioResourceConfigDedicated.mac_MainConfig);
return((enc_rval.encoded+7)/8); return((enc_rval.encoded+7)/8);
} }
...@@ -4114,6 +4118,25 @@ uint16_t do_RRCConnectionReconfiguration(const protocol_ctxt_t *const ctxt_pP, ...@@ -4114,6 +4118,25 @@ uint16_t do_RRCConnectionReconfiguration(const protocol_ctxt_t *const ctxt_pP,
// for (i=0;i<30;i++) // for (i=0;i<30;i++)
// msg("%x.",buffer[i]); // msg("%x.",buffer[i]);
// msg("\n"); // msg("\n");
if (securityConfigHO != NULL) {
free(rrcConnectionReconfiguration->criticalExtensions.choice.c1.choice.rrcConnectionReconfiguration_r8.securityConfigHO);
}
if (mobilityInfo !=NULL) {
free(rrcConnectionReconfiguration->criticalExtensions.choice.c1.choice.rrcConnectionReconfiguration_r8.mobilityControlInfo);
}
if (MeasId_list != NULL) {
if(speedStatePars != NULL) {
free(rrcConnectionReconfiguration->criticalExtensions.choice.c1.choice.rrcConnectionReconfiguration_r8.measConfig->speedStatePars);
}
if (quantityConfig!=NULL) {
free(rrcConnectionReconfiguration->criticalExtensions.choice.c1.choice.rrcConnectionReconfiguration_r8.measConfig->quantityConfig);
}
free(rrcConnectionReconfiguration->criticalExtensions.choice.c1.choice.rrcConnectionReconfiguration_r8.measConfig);
}
if (mac_MainConfig!=NULL) {
free(rrcConnectionReconfiguration->criticalExtensions.choice.c1.choice.rrcConnectionReconfiguration_r8.radioResourceConfigDedicated->mac_MainConfig);
}
free(rrcConnectionReconfiguration->criticalExtensions.choice.c1.choice.rrcConnectionReconfiguration_r8.radioResourceConfigDedicated);
return((enc_rval.encoded+7)/8); return((enc_rval.encoded+7)/8);
} }
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment