Fix potential NULL dereference
We document that either of recv or recv_timeout may be NULL, but for TLS we always used recv... Thanks Coverity for catching that. (Not remotely trigerrable: local configuration.) Also made me notice net_recv_timeout didn't do its job properly.
This commit is contained in:
parent
dba460f2f3
commit
0761733c1b
4 changed files with 19 additions and 6 deletions
|
@ -982,7 +982,7 @@ void mbedtls_ssl_conf_dbg( mbedtls_ssl_config *conf,
|
|||
* \param f_recv read callback
|
||||
* \param f_recv_timeout blocking read callback with timeout.
|
||||
* The last argument is the timeout in milliseconds,
|
||||
* 0 means no timeout
|
||||
* 0 means no timeout (block forever until a message comes)
|
||||
*
|
||||
* \note One of f_recv or f_recv_timeout can be NULL, in which case
|
||||
* the other is used. If both are non-NULL, f_recv_timeout is
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue