Assert on correct parameters (#1505)

This also fixes debug build
This commit is contained in:
Marcin Kolny 2022-09-20 01:58:02 +01:00 committed by GitHub
parent f96773410a
commit c072b5172c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -551,7 +551,8 @@ os_socket_set_linger(bh_socket_t socket, bool is_enabled, int linger_s)
int
os_socket_get_linger(bh_socket_t socket, bool *is_enabled, int *linger_s)
{
assert(time_s);
assert(is_enabled);
assert(linger_s);
struct linger linger_opts;
socklen_t linger_opts_len = sizeof(linger_opts);