Do not match singular stars when given a prefix in star search; bug #1071

git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@3540 8092fc87-c524-0410-9efc-e669fe64eaf9
This commit is contained in:
avolkov
2010-05-22 19:45:39 +00:00
parent fb828d599c
commit 581d7309b6
2 changed files with 9 additions and 3 deletions
+7 -3
View File
@@ -975,9 +975,13 @@ FindNextStarIndex (STAR_SEARCH_STATE *pSS, int from, BOOLEAN WithinClust)
continue;
}
if (!SDPtr->Prefix || WithinClust)
// singular star - prefix not checked
// or searching within clusters
if (pSS->Prefix && !SDPtr->Prefix)
// we were given a prefix but found a singular star;
// that is a no match
continue;
if (WithinClust)
// searching within clusters; any prefix is a match
break;
if (!pSS->Prefix)