Browse Source

cmRtSys.c: cmRtSysContext() now checks validity of rtSubIdx.

master
kevin 11 years ago
parent
commit
ca3fb3ec80
1 changed files with 3 additions and 0 deletions
  1. 3
    0
      cmRtSys.c

+ 3
- 0
cmRtSys.c View File

1220
   if( _cmRtSysVerifyInit(p,true) != kOkRtRC )
1220
   if( _cmRtSysVerifyInit(p,true) != kOkRtRC )
1221
     return NULL;
1221
     return NULL;
1222
 
1222
 
1223
+  if( rtSubIdx >= p->ssCnt )
1224
+    return NULL;
1225
+
1223
   return &p->ssArray[rtSubIdx].ctx;
1226
   return &p->ssArray[rtSubIdx].ctx;
1224
 }
1227
 }
1225
 
1228
 

Loading…
Cancel
Save