Skip to content

Commit

Permalink
help -i: properly error out if no info viewer can be found
Browse files Browse the repository at this point in the history
With this commit, git help -i <cmd> prints an error message and exits
non-zero instead of being silent and exit code 0.

Reported by Trent W. Buck through
 http://bugs.debian.org/537664

Signed-off-by: Gerrit Pape <pape@smarden.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Gerrit Pape authored and Junio C Hamano committed Oct 28, 2009
1 parent caa7dac commit a29aa47
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions builtin-help.c
Original file line number Diff line number Diff line change
Expand Up @@ -372,6 +372,7 @@ static void show_info_page(const char *git_cmd)
const char *page = cmd_to_page(git_cmd);
setenv("INFOPATH", system_path(GIT_INFO_PATH), 1);
execlp("info", "info", "gitman", page, NULL);
die("no info viewer handled the request");
}

static void get_html_page_path(struct strbuf *page_path, const char *page)
Expand Down

0 comments on commit a29aa47

Please sign in to comment.