qcacld-2.0: Fix integer overflow

'nRoamingTime' is 32bit integer, it can overflow when multipled
with PAL_TICKS_PER_SECOND so type cast it to 64bit before
multiplying to avoid overflow.

Change-Id: I66b303dc0631078cc442fcf3c95027bc224bf57f
This commit is contained in:
Rajshekar Eashwarappa 2019-08-16 16:43:37 +05:30 committed by L R
parent 7af813921a
commit 80efc95cd1
1 changed files with 1 additions and 1 deletions

View File

@ -11133,7 +11133,7 @@ tANI_BOOLEAN csrRoamCompleteRoaming(tpAniSirGlobal pMac, tANI_U32 sessionId,
tANI_BOOLEAN fForce, eCsrRoamResult roamResult)
{
tANI_BOOLEAN fCompleted = eANI_BOOLEAN_TRUE;
tANI_TIMESTAMP roamTime = (tANI_TIMESTAMP)(pMac->roam.configParam.nRoamingTime * PAL_TICKS_PER_SECOND);
tANI_TIMESTAMP roamTime = (tANI_TIMESTAMP)(pMac->roam.configParam.nRoamingTime) * PAL_TICKS_PER_SECOND;
tANI_TIMESTAMP curTime = (tANI_TIMESTAMP)palGetTickCount(pMac->hHdd);
tCsrRoamSession *pSession = CSR_GET_SESSION( pMac, sessionId );
if(!pSession)