Index: trunk/psLib/test/dataManip/tst_psMatrix03.c
===================================================================
--- trunk/psLib/test/dataManip/tst_psMatrix03.c	(revision 3264)
+++ trunk/psLib/test/dataManip/tst_psMatrix03.c	(revision 3313)
@@ -14,6 +14,6 @@
  *  @author  Ross Harman, MHPCC
  *
- *  @version $Revision: 1.14 $  $Name: not supported by cvs2svn $
- *  @date  $Date: 2005-02-17 19:26:25 $
+ *  @version $Revision: 1.15 $  $Name: not supported by cvs2svn $
+ *  @date  $Date: 2005-02-24 00:19:51 $
  *
  *  Copyright 2004-2005 Maui High Performance Computing Center, University of Hawaii
@@ -148,5 +148,4 @@
     printFooter(stdout, "psMatrix", "Calculate LU matrix", true);
 
-
     // Test C - Determine solution to matrix equation
     printPositiveTestHeader(stdout, "psMatrix", "Determine solution to matrix equation");
@@ -208,4 +207,5 @@
     psVector *vectorBadOut = (psVector*)psVectorAlloc(3, PS_TYPE_F64);
     psVector *permBad = (psVector*)psVectorAlloc(3, PS_TYPE_F64);
+    imageTest = (psImage*)psImageAlloc(3, 3, PS_TYPE_F64);
     psMatrixLUSolve(vectorBadOut, imageTest, vectorBad, permBad);
     printFooter(stdout, "psMatrix", "Attempt to use null input vector argument", true);
@@ -215,7 +215,20 @@
     printNegativeTestHeader(stdout,"psMatrix", "Attempt to use null LU image argument",
                             "Invalid operation: inImage or its data is NULL.", 0);
+    vectorBadOut = (psVector*)psVectorAlloc(3, PS_TYPE_F64);
     psMatrixLUSolve(vectorBadOut, NULL, vectorBad, permBad);
     printFooter(stdout, "psMatrix", "Attempt to use null LU image argument", true);
 
+    psFree(permBad);
+    psFree(imageTest);
+
+    if( psMemCheckLeaks(0, NULL, stdout, false) ) {
+        psError(PS_ERR_UNKNOWN,true,"Memory leaks detected");
+        return 10;
+    }
+    nBad = psMemCheckCorruption(0);
+    if(nBad) {
+        printf("ERROR: Found %d bad memory blocks\n", nBad);
+    }
+
     return 0;
 }
