diff options
author | Colin Watson <cjwatson@debian.org> | 2010-03-31 00:48:57 +0100 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2010-03-31 00:48:57 +0100 |
commit | d1a87e462e1db89f19cd960588d0c6b287cb5ccc (patch) | |
tree | f0d13e1687800f36a3c4322b94ac5230ad17bdbf /ssh-rand-helper.c | |
parent | 964476f91b66c475d5b8fa1e8b28d39a97a1b56e (diff) | |
parent | 004a7fb9c6a00b13dc98f56599918a54a3506d10 (diff) |
merge 5.4p1
Diffstat (limited to 'ssh-rand-helper.c')
-rw-r--r-- | ssh-rand-helper.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/ssh-rand-helper.c b/ssh-rand-helper.c index 8b1c4b4f4..fa5070499 100644 --- a/ssh-rand-helper.c +++ b/ssh-rand-helper.c | |||
@@ -818,6 +818,7 @@ main(int argc, char **argv) | |||
818 | unsigned char *buf; | 818 | unsigned char *buf; |
819 | int ret, ch, debug_level, output_hex, bytes; | 819 | int ret, ch, debug_level, output_hex, bytes; |
820 | extern char *optarg; | 820 | extern char *optarg; |
821 | extern int optind; | ||
821 | LogLevel ll; | 822 | LogLevel ll; |
822 | 823 | ||
823 | __progname = ssh_get_progname(argv[0]); | 824 | __progname = ssh_get_progname(argv[0]); |
@@ -853,11 +854,17 @@ main(int argc, char **argv) | |||
853 | default: | 854 | default: |
854 | error("Invalid commandline option"); | 855 | error("Invalid commandline option"); |
855 | usage(); | 856 | usage(); |
857 | exit(1); | ||
856 | } | 858 | } |
857 | } | 859 | } |
858 | |||
859 | log_init(argv[0], ll, SYSLOG_FACILITY_USER, 1); | 860 | log_init(argv[0], ll, SYSLOG_FACILITY_USER, 1); |
860 | 861 | ||
862 | if (argc != optind) { | ||
863 | error("Unexpected commandline arguments."); | ||
864 | usage(); | ||
865 | exit(1); | ||
866 | } | ||
867 | |||
861 | #ifdef USE_SEED_FILES | 868 | #ifdef USE_SEED_FILES |
862 | prng_read_seedfile(); | 869 | prng_read_seedfile(); |
863 | #endif | 870 | #endif |