git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 1/2] checkout: add missing const to describe_detached_head

From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Date
Feb 22, 2011, 22:43 UTC
Message-ID
<1298414603-22338-2-git-send-email-avarab@gmail.com>
In-Reply-To
<1298414603-22338-1-git-send-email-avarab@gmail.com>
From: Jonathan Nieder <jrnieder@gmail.com>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
---
 builtin/checkout.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/builtin/checkout.c b/builtin/checkout.c
index cd7f56e..bef324e 100644
--- a/builtin/checkout.c
+++ b/builtin/checkout.c
@@ -297,7 +297,7 @@ static void show_local_changes(struct object *head, struct diff_options *opts)
 	run_diff_index(&rev, 0);
 }
 
-static void describe_detached_head(char *msg, struct commit *commit)
+static void describe_detached_head(const char *msg, struct commit *commit)
 {
 	struct strbuf sb = STRBUF_INIT;
 	struct pretty_print_context ctx = {0};
-- 
1.7.2.3
Previous: Ævar Arnfjörð BjarmasonNext: Ævar Arnfjörð Bjarmason
Message 2 of 3 in “Add missing const to char* declarations”
  1. 0/2 Add missing const to char* declarationsÆvar Arnfjörð Bjarmason, Feb 22, 2011
  2. 1/2 checkout: add missing const to describe_detached_headÆvar Arnfjörð Bjarmason, Feb 22, 2011
  3. 2/2 update-index --refresh --porcelain: add missing constÆvar Arnfjörð Bjarmason, Feb 22, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.