diff options
author | Matt Caswell <matt@openssl.org> | 2015-10-22 10:45:29 +0100 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2015-10-30 08:38:18 +0000 |
commit | 5e41ba031edd91bfbac6a614664f83b22fb48207 (patch) | |
tree | f01b707fee80954a1e24fd3cf272e72cd4536f46 | |
parent | c64359db8af1bf759f4496a01c93bac658decc7e (diff) |
Convert DTLSv1_listen to use new state machine code
The DTLSv1_listen code set the state value explicitly to move into init.
Change to use state_set_in_init() instead.
Reviewed-by: Tim Hudson <tjh@openssl.org>
Reviewed-by: Richard Levitte <levitte@openssl.org>
-rw-r--r-- | ssl/d1_lib.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/ssl/d1_lib.c b/ssl/d1_lib.c index 3a0a4cf443..3bc9fe7362 100644 --- a/ssl/d1_lib.c +++ b/ssl/d1_lib.c @@ -868,11 +868,8 @@ int dtls1_listen(SSL *s, struct sockaddr *client) */ SSL_set_options(s, SSL_OP_COOKIE_EXCHANGE); - /* - * Put us into the "init" state so that dtls1_accept doesn't clear our - * state - */ - s->state = SSL_ST_ACCEPT; + /* Put us into the "init" state so that we don't get our state cleared */ + statem_set_in_init(s, 1); if(BIO_dgram_get_peer(rbio, client) <= 0) { SSLerr(SSL_F_DTLS1_LISTEN, ERR_R_INTERNAL_ERROR); |