]> git.donarmstrong.com Git - mothur.git/blobdiff - matrixoutputcommand.cpp
fixed some issues while testing 1.6
[mothur.git] / matrixoutputcommand.cpp
index 00dff4bc963cb277787bc232f6ae4a3484084542..9b4935f5ec076ddc870ed7716b0588184e13dee4 100644 (file)
@@ -246,7 +246,7 @@ int MatrixOutputCommand::execute(){
                
                //run last line if you need to
                if (needToRun == true)  {
-                       for (int i = 0; i < lookup.size(); i++) {  delete lookup[i];  } 
+                       for (int i = 0; i < lookup.size(); i++) {  if (lookup[i] != NULL) {  delete lookup[i]; }  } 
                        lookup = input->getSharedRAbundVectors(lastLabel);
 
                        mothurOut(lookup[0]->getLabel()); mothurOutEndLine();