Skip to content

Commit

Permalink
builtin-init-db: use warning() instead of fprintf(stderr, "warning: ")
Browse files Browse the repository at this point in the history
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Miklos Vajna authored and Junio C Hamano committed Mar 24, 2009
1 parent 78509d2 commit 2fd8c0a
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions builtin-init-db.c
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,7 @@ static void copy_templates(const char *template_dir)
}
dir = opendir(template_path);
if (!dir) {
fprintf(stderr, "warning: templates not found %s\n",
template_dir);
warning("templates not found %s", template_dir);
return;
}

Expand All @@ -144,8 +143,8 @@ static void copy_templates(const char *template_dir)

if (repository_format_version &&
repository_format_version != GIT_REPO_VERSION) {
fprintf(stderr, "warning: not copying templates of "
"a wrong format version %d from '%s'\n",
warning("not copying templates of "
"a wrong format version %d from '%s'",
repository_format_version,
template_dir);
closedir(dir);
Expand Down

0 comments on commit 2fd8c0a

Please sign in to comment.