From: ueno Date: Fri, 11 Aug 2006 01:25:17 +0000 (+0000) Subject: * starttls.c (main): Added --help option. X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b5f8877ea32d965b0b0799de37049af7586b0155;p=elisp%2Fstarttls.git * starttls.c (main): Added --help option. --- diff --git a/ChangeLog b/ChangeLog index 074639b..4392923 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2006-08-11 Daiki Ueno + + * starttls.c (main): Added --help option. + 2006-08-10 Daiki Ueno * starttls.c (main): Use poll(2) emulation from gnulib; avoid some diff --git a/starttls.c b/starttls.c index 4127db7..3002201 100644 --- a/starttls.c +++ b/starttls.c @@ -135,12 +135,13 @@ main (argc, argv) { {"cert-file", 1, 0, 'c'}, {"key-file", 1, 0, 'k'}, + {"help", 0, 0, 'h'}, {0, 0, 0, 0} }; while (1) { - c = getopt_long (argc, argv, "c:k:", long_options, &option_index); + c = getopt_long (argc, argv, "c:k:h", long_options, &option_index); if (c == -1) break; @@ -152,6 +153,9 @@ main (argc, argv) case 'k': opt_key_file = optarg; break; + case 'h': + usage (argv[0]); + return 0; default: usage (argv[0]); return 1;