Commits

Dmitry Karpeyev committed 11c04cc

Bug fix in test of MatGetSubMatrices().

Hg-commit: f82ceb0f3af5e61ef44bd83c02d5780d046c33e0

  • Participants
  • Parent commits 66b83a8

Comments (0)

Files changed (1)

src/mat/examples/tests/ex92.c

 
   /* Test MatGetSubmatrices */
   if (TestSubMat){
-    ierr = ISSort(is1[i]); CHKERRQ(ierr);
-    ierr = ISSort(is2[i]); CHKERRQ(ierr);
+    for(i = 0; i < nd; ++i) {
+      ierr = ISSort(is1[i]); CHKERRQ(ierr);
+      ierr = ISSort(is2[i]); CHKERRQ(ierr);
+    }
     ierr = MatGetSubMatrices(A,nd,is1,is1,MAT_INITIAL_MATRIX,&submatA);CHKERRQ(ierr);
     ierr = MatGetSubMatrices(sA,nd,is2,is2,MAT_INITIAL_MATRIX,&submatsA);CHKERRQ(ierr);