qcacld-3.0: Check for max num of num_dscp_exceptions in limLogQosMapSet

qcacld-2.0 to qcacld-3.0 propagation
In limLogQosMapSet, dscp_exceptions is max of 21 size but
there is no limit check for num_dscp_exceptions.
Check for max size for num_dscp_exceptions to avoid overflow.

Change-Id: Ia1f64860f924aa0d586b2d0d532183ef9b18f2e0
CRs-Fixed: 933465
This commit is contained in:
Agrawal Ashish 2016-09-16 21:57:22 +05:30 • committed by Gerrit - the friendly Code Review server
commit afe4ca0324

View file

@ -935,6 +935,8 @@ void lim_log_operating_mode(tpAniSirGlobal pMac, tDot11fIEOperatingMode *pDot11f
void lim_log_qos_map_set(tpAniSirGlobal pMac, tSirQosMapSet *pQosMapSet)
{
uint8_t i;
if (pQosMapSet->num_dscp_exceptions > QOS_MAP_MAX_EX)
pQosMapSet->num_dscp_exceptions = QOS_MAP_MAX_EX;
lim_log(pMac, LOG1, FL("num of dscp exceptions : %d"),
pQosMapSet->num_dscp_exceptions);
for (i = 0; i < pQosMapSet->num_dscp_exceptions; i++) {