diff options
author | Kinichiro Inoguchi <inoguchi@cvs.openbsd.org> | 2020-04-26 01:59:28 +0000 |
---|---|---|
committer | Kinichiro Inoguchi <inoguchi@cvs.openbsd.org> | 2020-04-26 01:59:28 +0000 |
commit | 3b829e3d9229c997bec241541a0cd3c2c99f5bb3 (patch) | |
tree | feb43d7a908b505d30801747aa6cbb7372da09ce /usr.bin/openssl | |
parent | a3ff036d7d34df9a8f345a6308335e238321a8a8 (diff) |
s_client: fix use of possibly uninitialized values
Set initial value to variable 'p' and 'pending'.
Reported and fix requested from leonklingele by GitHub pull request.
https://github.com/libressl-portable/portable/issues/577
https://github.com/libressl-portable/openbsd/pull/114
ok bcook@ jsing@ tb@
Diffstat (limited to 'usr.bin/openssl')
-rw-r--r-- | usr.bin/openssl/s_client.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/openssl/s_client.c b/usr.bin/openssl/s_client.c index 02db7feac85..27516ae5dba 100644 --- a/usr.bin/openssl/s_client.c +++ b/usr.bin/openssl/s_client.c @@ -1,4 +1,4 @@ -/* $OpenBSD: s_client.c,v 1.43 2020/04/19 17:05:55 jsing Exp $ */ +/* $OpenBSD: s_client.c,v 1.44 2020/04/26 01:59:27 inoguchi Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -293,7 +293,7 @@ s_client_main(int argc, char **argv) { unsigned int off = 0, clr = 0; SSL *con = NULL; - int s, k, p, pending, state = 0, af = AF_UNSPEC; + int s, k, p = 0, pending = 0, state = 0, af = AF_UNSPEC; char *cbuf = NULL, *sbuf = NULL, *mbuf = NULL, *pbuf = NULL; int cbuf_len, cbuf_off; int sbuf_len, sbuf_off; |