global: improve const correctness when assigning string constants
We're about to enable `-Wwrite-strings`, which changes the type of string constants to `const char[]`. Fix various sites where we assign such constants to non-const variables. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
5529cba09f
commit
b567004b4b
@ -1283,7 +1283,7 @@ static void get_patch_ids(struct rev_info *rev, struct patch_ids *ids)
|
||||
o2->flags = flags2;
|
||||
}
|
||||
|
||||
static void gen_message_id(struct rev_info *info, char *base)
|
||||
static void gen_message_id(struct rev_info *info, const char *base)
|
||||
{
|
||||
struct strbuf buf = STRBUF_INIT;
|
||||
strbuf_addf(&buf, "%s.%"PRItime".git.%s", base,
|
||||
|
||||
Reference in New Issue
Block a user