Index: /issm/trunk-jpl/src/c/modules/SetActiveNodesLSMx/SetActiveNodesLSMx.cpp
===================================================================
--- /issm/trunk-jpl/src/c/modules/SetActiveNodesLSMx/SetActiveNodesLSMx.cpp	(revision 25335)
+++ /issm/trunk-jpl/src/c/modules/SetActiveNodesLSMx/SetActiveNodesLSMx.cpp	(revision 25336)
@@ -62,5 +62,6 @@
 	int numvertices=femmodel->vertices->NumberOfVertices();
 	if(numvertices==0)  return;
-	Vector<IssmDouble>* vec_mask_ice=new Vector<IssmDouble>(numvertices);
+	int numvertices_local=femmodel->vertices->NumberOfVerticesLocal();
+	Vector<IssmDouble>* vec_mask_ice=new Vector<IssmDouble>(numvertices,numvertices_local);
 
 	/*Fill vector with values: */
Index: /issm/trunk-jpl/src/c/toolkits/gsl/DenseGslSolve.cpp
===================================================================
--- /issm/trunk-jpl/src/c/toolkits/gsl/DenseGslSolve.cpp	(revision 25335)
+++ /issm/trunk-jpl/src/c/toolkits/gsl/DenseGslSolve.cpp	(revision 25336)
@@ -319,4 +319,6 @@
   xDelete(valueX);
   xDelete(indexX);
+ 
+  delete data;
 }
 /*}}}*/
@@ -374,5 +376,6 @@
 
     tape.pushExternalFunctionHandle(&SolverxSeq_codi_b, dataHandler, &SolverxSeq_codi_delete);
-  } else {
+  }
+  else{
     // if the tape is active valueX is stored in the dataHandler and deleted in the reverse sweep
     xDelete(valueX);
Index: /issm/trunk-jpl/src/c/toolkits/issm/IssmMpiVec.h
===================================================================
--- /issm/trunk-jpl/src/c/toolkits/issm/IssmMpiVec.h	(revision 25335)
+++ /issm/trunk-jpl/src/c/toolkits/issm/IssmMpiVec.h	(revision 25336)
@@ -36,4 +36,5 @@
 	public:
 
+		bool isassembled;
 		int M; //global size
 		int m; //local number of rows
@@ -46,4 +47,5 @@
 			this->M=0;
 			this->m=0;
+			this->isassembled=false;
 			this->vector=NULL;
 			this->buckets=new DataSet();
@@ -102,4 +104,5 @@
 
 			this->buckets=new DataSet();
+			this->isassembled=false;
 
 			if(fromlocalsize){
@@ -137,8 +140,20 @@
 		void Echo(void){/*{{{*/
 
-			int i,j;
-
 			/*Do a synchronized dump across all the rows: */
-			for(i=0;i<IssmComm::GetSize();i++){
+			int my_rank=IssmComm::GetRank();
+			for(int i=0;i<IssmComm::GetSize();i++){
+				if(my_rank==i){
+					if(i==0) _printf_("Vector of global size M="<<this->M<<"\n");
+					_printf_("cpu " << i << " #rows: " << this->m << "\n");
+					if(this->isassembled){
+						for(int j=0;j<this->m;j++){
+							_printf_("row " << j << ": "<<this->vector[j]);
+							_printf_("\n");
+						}
+					}
+					else{
+						this->buckets->DeepEcho();
+					}
+				}
 				ISSM_MPI_Barrier(IssmComm::GetComm());
 			}
@@ -236,7 +251,7 @@
 			count=0;
 			for(i=0;i<num_procs;i++){
-				sendcnts[i]=numvalues_forcpu[i];
-				displs[i]=count;
-				count+=numvalues_forcpu[i];
+				sendcnts[i] = numvalues_forcpu[i];
+				displs[i]   = count;
+				count      += numvalues_forcpu[i];
 			}
 
@@ -262,4 +277,5 @@
 			}
 			/*}}}*/
+			this->isassembled=true;
 
 			/*Free ressources:{{{*/
Index: /issm/trunk-jpl/src/c/toolkits/mumps/MumpsSolve.cpp
===================================================================
--- /issm/trunk-jpl/src/c/toolkits/mumps/MumpsSolve.cpp	(revision 25335)
+++ /issm/trunk-jpl/src/c/toolkits/mumps/MumpsSolve.cpp	(revision 25336)
@@ -576,4 +576,6 @@
   xDelete(valueX);
   xDelete(indexX);
+
+  delete data;
 }
 /*}}}*/
@@ -638,5 +640,6 @@
 	 //tape.pushExternalFunction(&MumpsSolve_codi_b, dataHandler, &MumpsSolve_codi_delete);
     tape.pushExternalFunctionHandle(&MumpsSolve_codi_b,(void*)dataHandler, &MumpsSolve_codi_delete);
-  } else {
+  }
+  else{
     // if the tape is active valueB is stored in the dataHandler and deleted in the reverse sweep
     xDelete(valueB);
