diff options
| author | jsing <> | 2014-08-27 15:54:02 +0000 |
|---|---|---|
| committer | jsing <> | 2014-08-27 15:54:02 +0000 |
| commit | 7dc71ba736b520c421be464499172e09306068a6 (patch) | |
| tree | ce27f73a3621f47fc9f089d37a6f0f954828bc88 /src/usr.bin/openssl/rand.c | |
| parent | 839339c9fa71184602e0387ff9ed447d4d87415b (diff) | |
| download | openbsd-7dc71ba736b520c421be464499172e09306068a6.tar.gz openbsd-7dc71ba736b520c421be464499172e09306068a6.tar.bz2 openbsd-7dc71ba736b520c421be464499172e09306068a6.zip | |
Reset the config struct before calling options_parse(), otherwise config
options from the previous run stick in interactive mode.
Diffstat (limited to 'src/usr.bin/openssl/rand.c')
| -rw-r--r-- | src/usr.bin/openssl/rand.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/usr.bin/openssl/rand.c b/src/usr.bin/openssl/rand.c index 61c7013340..cfb8d763b0 100644 --- a/src/usr.bin/openssl/rand.c +++ b/src/usr.bin/openssl/rand.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: rand.c,v 1.2 2014/08/27 14:59:44 jsing Exp $ */ | 1 | /* $OpenBSD: rand.c,v 1.3 2014/08/27 15:54:02 jsing Exp $ */ |
| 2 | /* ==================================================================== | 2 | /* ==================================================================== |
| 3 | * Copyright (c) 1998-2001 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1998-2001 The OpenSSL Project. All rights reserved. |
| 4 | * | 4 | * |
| @@ -122,6 +122,8 @@ rand_main(int argc, char **argv) | |||
| 122 | int i, r; | 122 | int i, r; |
| 123 | BIO *out = NULL; | 123 | BIO *out = NULL; |
| 124 | 124 | ||
| 125 | memset(&rand_config, 0, sizeof(rand_config)); | ||
| 126 | |||
| 125 | if (options_parse(argc, argv, rand_options, &num_bytes) != 0) { | 127 | if (options_parse(argc, argv, rand_options, &num_bytes) != 0) { |
| 126 | rand_usage(); | 128 | rand_usage(); |
| 127 | return (1); | 129 | return (1); |
