Browse Source

cmProc4.c: Changed size validation in _cmScMatchInitMtx() to eliminate crash bug.

master
kevin 11 years ago
parent
commit
9fd7c97cc3
1 changed files with 2 additions and 1 deletions
  1. 2
    1
      cmProc4.c

+ 2
- 1
cmProc4.c View File

@@ -1275,7 +1275,8 @@ cmRC_t     cmScMatchFinal( cmScMatch* p )
1275 1275
 
1276 1276
 cmRC_t  _cmScMatchInitMtx( cmScMatch* p, unsigned rn, unsigned cn )
1277 1277
 {
1278
-  if( rn >p->mrn && cn > p->mcn )
1278
+  //if( rn >p->mrn && cn > p->mcn )
1279
+  if( rn*cn > p->mrn*p->mcn )
1279 1280
     return cmCtxRtCondition( &p->obj, cmInvalidArgRC, "MIDI sequence length must be less than %i. Score sequence length must be less than %i.",p->mmn,p->msn); 
1280 1281
 
1281 1282
   // if the size of the mtx is not changing then there is nothing to do

Loading…
Cancel
Save