ENH: fix for flags that have sub-string matches
This commit is contained in:
parent
fc8b27650c
commit
4bc39940c3
|
@ -997,7 +997,7 @@ std::string cmGlobalXCodeGenerator::ExtractFlag(const char* flag,
|
||||||
{
|
{
|
||||||
std::string retFlag;
|
std::string retFlag;
|
||||||
std::string::size_type pos = flags.find(flag);
|
std::string::size_type pos = flags.find(flag);
|
||||||
if(pos != flags.npos)
|
if(pos != flags.npos && (pos ==0 || flags[pos]==' '))
|
||||||
{
|
{
|
||||||
while(pos < flags.size() && flags[pos] != ' ')
|
while(pos < flags.size() && flags[pos] != ' ')
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue