Replace remaining instances of strdup with xstrdup.
Signed-off-by: James Bowes <jbowes@dangerouslyinc.com> Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:

committed by
Junio C Hamano

parent
5e08ecbff2
commit
567fb65e25
2
commit.c
2
commit.c
@ -706,7 +706,7 @@ static char *logmsg_reencode(const struct commit *commit,
|
||||
encoding = get_header(commit, "encoding");
|
||||
use_encoding = encoding ? encoding : utf8;
|
||||
if (!strcmp(use_encoding, output_encoding))
|
||||
out = strdup(commit->buffer);
|
||||
out = xstrdup(commit->buffer);
|
||||
else
|
||||
out = reencode_string(commit->buffer,
|
||||
output_encoding, use_encoding);
|
||||
|
Reference in New Issue
Block a user