path.c: make get_pathname() call sites return const char *
[gitweb.git] / builtin / checkout.c
index 5410dacea0699f70cd942837394c06eac99873d1..c600ec14c71dc100669f57fbc989480e9a799e73 100644 (file)
@@ -589,7 +589,7 @@ static void update_refs_for_switch(const struct checkout_opts *opts,
                        if (opts->new_branch_log && !log_all_ref_updates) {
                                int temp;
                                char log_file[PATH_MAX];
-                               char *ref_name = mkpath("refs/heads/%s", opts->new_orphan_branch);
+                               const char *ref_name = mkpath("refs/heads/%s", opts->new_orphan_branch);
 
                                temp = log_all_ref_updates;
                                log_all_ref_updates = 1;