Index: trunk/psLib/src/dataManip/psMatrixVectorArithmetic.c
===================================================================
--- trunk/psLib/src/dataManip/psMatrixVectorArithmetic.c	(revision 2680)
+++ trunk/psLib/src/dataManip/psMatrixVectorArithmetic.c	(revision 2692)
@@ -29,6 +29,6 @@
  *  @author Ross Harman, MHPCC
  *
- *  @version $Revision: 1.31 $ $Name: not supported by cvs2svn $
- *  @date $Date: 2004-12-09 23:31:14 $
+ *  @version $Revision: 1.32 $ $Name: not supported by cvs2svn $
+ *  @date $Date: 2004-12-10 21:37:37 $
  *
  *  Copyright 2004 Maui High Performance Computing Center, University of Hawaii
@@ -813,4 +813,8 @@
             PS_ERRORTEXT_psMatrix_OPERATION_UNSUPPORTED,                                                     \
             OP);                                                                                             \
+    if (OUT != IN) {                                                                                         \
+        psFree(OUT);                                                                                         \
+    }                                                                                                        \
+    return NULL;                                                                                             \
 }
 
@@ -820,7 +824,4 @@
                              if (out != in) { \
                              psFree(out); \
-                             } \
-                             if(psTypeIn->dimen==PS_DIMEN_SCALAR && in!=out) { \
-                             psFree(in); \
                              } \
                              return NULL; \
