Parcourir la source

[1470] Corrected data type of index into vector

Stephen Morris il y a 13 ans
Parent
commit
0fd58479c4
1 fichiers modifiés avec 1 ajouts et 1 suppressions
  1. 1 1
      src/lib/util/strutil.cc

+ 1 - 1
src/lib/util/strutil.cc

@@ -120,7 +120,7 @@ format(const std::string& format, const std::vector<std::string>& args) {
     // Iterate through replacing all tokens
     result = format;
     size_t tokenpos = 0;    // Position of last token replaced
-    int i = 0;              // Index into argument array
+    std::vector<std::string>::size_type i = 0; // Index into argument array
 
     while ((i < args.size()) && (tokenpos != string::npos)) {
         tokenpos = result.find(flag, tokenpos);