mirror of
https://github.com/osmarks/ngircd.git
synced 2025-06-20 23:34:09 +00:00
SSL/TLS: clear all ssl realted flags on shutdown
one ssl related flags was not cleared on ssl shutdown. introduce and use CONN_SSL_FLAGS_ALL to zap them all.
This commit is contained in:
parent
c6a43fbaf0
commit
2fce4667a8
@ -228,7 +228,8 @@ void ConnSSL_Free(CONNECTION *c)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
assert(Conn_OPTION_ISSET(c, CONN_SSL));
|
assert(Conn_OPTION_ISSET(c, CONN_SSL));
|
||||||
Conn_OPTION_DEL(c, (CONN_SSL_CONNECT|CONN_SSL|CONN_SSL_WANT_WRITE));
|
/* can't just set bitmask to 0 -- there are other, non-ssl related flags, e.g. CONN_ZIP. */
|
||||||
|
Conn_OPTION_DEL(c, CONN_SSL_FLAGS_ALL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -39,6 +39,7 @@
|
|||||||
#define CONN_SSL 32 /* this connection is SSL encrypted */
|
#define CONN_SSL 32 /* this connection is SSL encrypted */
|
||||||
#define CONN_SSL_WANT_WRITE 64 /* SSL/TLS library needs to write protocol data */
|
#define CONN_SSL_WANT_WRITE 64 /* SSL/TLS library needs to write protocol data */
|
||||||
#define CONN_SSL_WANT_READ 128 /* SSL/TLS library needs to read protocol data */
|
#define CONN_SSL_WANT_READ 128 /* SSL/TLS library needs to read protocol data */
|
||||||
|
#define CONN_SSL_FLAGS_ALL (CONN_SSL_CONNECT|CONN_SSL|CONN_SSL_WANT_WRITE|CONN_SSL_WANT_READ)
|
||||||
#endif
|
#endif
|
||||||
typedef int CONN_ID;
|
typedef int CONN_ID;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user