X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=builtin%2Fshortlog.c;h=2135b0dde11faa0c501682ed074e0ba96bf28b42;hb=385cc9d8c44eb5be9d57e630129752a72c0a08c8;hp=0a9681ba7ece52e751b1b54d53f3e8fb4c19464e;hpb=aa57328d60f5d5a5f74d1d336caf06b6bdf4fd03;p=git.git diff --git a/builtin/shortlog.c b/builtin/shortlog.c index 0a9681ba7..2135b0dde 100644 --- a/builtin/shortlog.c +++ b/builtin/shortlog.c @@ -249,7 +249,7 @@ int cmd_shortlog(int argc, const char **argv, const char *prefix) { static struct shortlog log; static struct rev_info rev; - int nongit; + int nongit = !startup_info->have_repository; static const struct option options[] = { OPT_BOOLEAN('n', "numbered", &log.sort_by_number, @@ -265,7 +265,6 @@ int cmd_shortlog(int argc, const char **argv, const char *prefix) struct parse_opt_ctx_t ctx; - prefix = setup_git_directory_gently(&nongit); git_config(git_default_config, NULL); shortlog_init(&log); init_revisions(&rev, prefix);