X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=chimeracheckrdp.cpp;fp=chimeracheckrdp.cpp;h=e89277b12078c089688c9c1cba7f9abe734ea8bc;hb=e0fbf58358a72f20352cf2a43922ab6b5bdf0cf8;hp=4c93c1b97c5c7edd2a583cb449cf34440be2a324;hpb=fbaa6c7ac44f857c1ece7c8199e9e7e09b4bbe74;p=mothur.git diff --git a/chimeracheckrdp.cpp b/chimeracheckrdp.cpp index 4c93c1b..e89277b 100644 --- a/chimeracheckrdp.cpp +++ b/chimeracheckrdp.cpp @@ -315,25 +315,26 @@ int ChimeraCheckRDP::calcKmers(map query, map subject) { try{ int common = 0; - map::iterator small; - map::iterator large; + map::iterator smallone; + map::iterator largeone; + if (query.size() < subject.size()) { - for (small = query.begin(); small != query.end(); small++) { - large = subject.find(small->first); + for (smallone = query.begin(); smallone != query.end(); smallone++) { + largeone = subject.find(smallone->first); //if you found it they have that kmer in common - if (large != subject.end()) { common++; } + if (largeone != subject.end()) { common++; } } }else { - for (small = subject.begin(); small != subject.end(); small++) { - large = query.find(small->first); + for (smallone = subject.begin(); smallone != subject.end(); smallone++) { + largeone = query.find(smallone->first); //if you found it they have that kmer in common - if (large != query.end()) { common++; } + if (largeone != query.end()) { common++; } } }