Browse Source

use xstrdup please

We generally prefer xstrdup to just plain strdup.
Make it so.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
maint
Shawn O. Pearce 18 years ago committed by Junio C Hamano
parent
commit
dbb2b41aa4
  1. 4
      config.c

4
config.c

@ -351,12 +351,12 @@ int git_default_config(const char *var, const char *value)
} }


if (!strcmp(var, "i18n.commitencoding")) { if (!strcmp(var, "i18n.commitencoding")) {
git_commit_encoding = strdup(value); git_commit_encoding = xstrdup(value);
return 0; return 0;
} }


if (!strcmp(var, "i18n.logoutputencoding")) { if (!strcmp(var, "i18n.logoutputencoding")) {
git_log_output_encoding = strdup(value); git_log_output_encoding = xstrdup(value);
return 0; return 0;
} }



Loading…
Cancel
Save