Index: /issm/trunk/src/c/objects/Numerics/ElementMatrix.cpp
===================================================================
--- /issm/trunk/src/c/objects/Numerics/ElementMatrix.cpp	(revision 5787)
+++ /issm/trunk/src/c/objects/Numerics/ElementMatrix.cpp	(revision 5788)
@@ -190,5 +190,5 @@
 
 
-			if(this->row_ssize){
+			if((this->row_ssize!=0) && (this->row_fsize!=0)){
 				/*first, retrieve values that are in the f and s-set from the g-set values matrix: */
 				internalvalues=(double*)xmalloc(this->row_fsize*this->row_ssize*sizeof(double));
