radiant/buildmenu: fixup, ref #138
authorThomas Debesse <dev@illwieckz.net>
Sat, 28 Mar 2020 00:52:57 +0000 (01:52 +0100)
committerThomas Debesse <dev@illwieckz.net>
Sat, 28 Mar 2020 00:52:57 +0000 (01:52 +0100)
radiant/build.cpp

index 9000f3b..c060d08 100644 (file)
@@ -83,10 +83,10 @@ void evaluate( StringBuffer& output ){
                const char *pattern = ".[ExecutableType]";
                for ( const char *i = m_string.c_str(); *i != '\0'; ++i )
                {
-                       if ( strcmp( pattern, i ) == 0 )
+                       if ( strncmp( pattern, i, sizeof( pattern ) ) == 0 )
                        {
                                output.push_string("");
-                               i += strlen( pattern );
+                               i += strlen( pattern ) - 1;
                        }
                        else
                        {