]> de.git.xonotic.org Git - xonotic/netradiant.git/commitdiff
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 9000f3b1300aa8f5775c8ab07a008bbb6f1f6e5e..c060d08ffdf083ebdb0420ad55db467ad1886ccc 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 )
                {
                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("");
                        {
                                output.push_string("");
-                               i += strlen( pattern );
+                               i += strlen( pattern ) - 1;
                        }
                        else
                        {
                        }
                        else
                        {