]> granicus.if.org Git - vim/commitdiff
Avoid compiler warnings for size_t to int conversions.
authorBram Moolenaar <Bram@vim.org>
Fri, 16 Jul 2010 18:38:52 +0000 (20:38 +0200)
committerBram Moolenaar <Bram@vim.org>
Fri, 16 Jul 2010 18:38:52 +0000 (20:38 +0200)
src/misc1.c

index 493b532bd358fd7a68cd9e4fc5c31cd05c1c2cb9..4b0ff6df34d0ff04acaa3af3c3a0cdddb65ab90f 100644 (file)
@@ -9273,8 +9273,8 @@ is_unique(maybe_unique, gap, i)
        if (j == i)
            continue;
 
-       candidate_len = STRLEN(maybe_unique);
-       other_path_len = STRLEN(other_paths[j]);
+       candidate_len = (int)STRLEN(maybe_unique);
+       other_path_len = (int)STRLEN(other_paths[j]);
 
        if (other_path_len < candidate_len)
            continue;  /* it's different */
@@ -9327,7 +9327,7 @@ uniquefy_paths(gap, pattern)
      * regex matches anywhere in the path. FIXME: is this valid for all
      * possible pattern?
      */
-    len = STRLEN(pattern);
+    len = (int)STRLEN(pattern);
     file_pattern = alloc(len + 2);
     file_pattern[0] = '*';
     file_pattern[1] = '\0';
@@ -9347,7 +9347,7 @@ uniquefy_paths(gap, pattern)
     for (i = 0; i < gap->ga_len; i++)
     {
        path = fnames[i];
-       len = STRLEN(path);
+       len = (int)STRLEN(path);
 
        /* we start at the end of the path */
        pathsep_p = path + len - 1;