From: Shawn O. Pearce Date: Mon, 28 Aug 2006 00:13:44 +0000 (-0400) Subject: Don't crash fast-import if no branch log was requested. X-Git-Tag: v1.5.0-rc4~14^2~55 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/08d7e892a714dec8471cd45add2b1da24f66b3e7 Don't crash fast-import if no branch log was requested. Signed-off-by: Shawn O. Pearce --- diff --git a/fast-import.c b/fast-import.c index 778b8bfdd4..5376b5e15c 100644 --- a/fast-import.c +++ b/fast-import.c @@ -1715,7 +1715,8 @@ int main(int argc, const char **argv) dump_branches(); dump_tags(); dump_marks(); - fclose(branch_log); + if (branch_log) + fclose(branch_log); fprintf(stderr, "%s statistics:\n", argv[0]); fprintf(stderr, "---------------------------------------------------\n");