X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=mothurout.cpp;h=fe3ea097e64faf1b0418f22fa3b248b026ad4dd1;hb=27554f2d86c52785a573d4a9fb0cbcc6a3602269;hp=5c5fd373a32cbb233fb9a76dd81de87c54cb80eb;hpb=4c880478c8db840cc6c3f10b9c7ddd8d0d3da332;p=mothur.git diff --git a/mothurout.cpp b/mothurout.cpp index 5c5fd37..fe3ea09 100644 --- a/mothurout.cpp +++ b/mothurout.cpp @@ -1179,17 +1179,33 @@ void MothurOut::splitAtDash(string& estim, set& container) { //This function parses the a string and puts peices in a vector void MothurOut::splitAtComma(string& estim, vector& container) { try { - string individual; - - while (estim.find_first_of(',') != -1) { - individual = estim.substr(0,estim.find_first_of(',')); - if ((estim.find_first_of(',')+1) <= estim.length()) { //checks to make sure you don't have comma at end of string - estim = estim.substr(estim.find_first_of(',')+1, estim.length()); + string individual = ""; + int estimLength = estim.size(); + for(int i=0;i