]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
reduce scope of variable
authorAmadeusz Sławiński <amade@asmblr.net>
Wed, 22 Feb 2017 14:05:52 +0000 (15:05 +0100)
committerAmadeusz Sławiński <amade@asmblr.net>
Wed, 22 Feb 2017 14:05:52 +0000 (15:05 +0100)
qcsrc/common/util.qc

index 0a371ff0004c7fc9430cbec14668c4a77ccb222e..118d60d23f25c1495f0653a6666a66e8651a1376 100644 (file)
@@ -779,8 +779,7 @@ string find_last_color_code(string s)
        if (start == -1) // no caret found
                return "";
        int len = strlen(s)-1;
-       int i;
-       for(i = len; i >= start; --i)
+       for(int i = len; i >= start; --i)
        {
                if(substring(s, i, 1) != "^")
                        continue;