Convert "struct cache_entry *" to "const ..." wherever possible
[gitweb.git] / builtin / grep.c
index 159e65d47a41b56634bc3fb480f9c051d40e692c..0223d701a6cb2824733f72fc04d298a9c8c87020 100644 (file)
@@ -376,7 +376,7 @@ static int grep_cache(struct grep_opt *opt, const struct pathspec *pathspec, int
        read_cache();
 
        for (nr = 0; nr < active_nr; nr++) {
-               struct cache_entry *ce = active_cache[nr];
+               const struct cache_entry *ce = active_cache[nr];
                if (!S_ISREG(ce->ce_mode))
                        continue;
                if (!match_pathspec_depth(pathspec, ce->name, ce_namelen(ce), 0, NULL))