cmRtSys.c: cmRtSysContext() now checks validity of rtSubIdx.
This commit is contained in:
parent
3f1821b0be
commit
ca3fb3ec80
@ -1220,6 +1220,9 @@ cmRtSysCtx_t* cmRtSysContext( cmRtSysH_t h, unsigned rtSubIdx )
|
|||||||
if( _cmRtSysVerifyInit(p,true) != kOkRtRC )
|
if( _cmRtSysVerifyInit(p,true) != kOkRtRC )
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
|
if( rtSubIdx >= p->ssCnt )
|
||||||
|
return NULL;
|
||||||
|
|
||||||
return &p->ssArray[rtSubIdx].ctx;
|
return &p->ssArray[rtSubIdx].ctx;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user