diff options
author | Jan Moskyto Matejka <mq@ucw.cz> | 2016-09-29 12:00:53 +0200 |
---|---|---|
committer | Jan Moskyto Matejka <mq@ucw.cz> | 2016-09-29 13:21:16 +0200 |
commit | ccd2a3eda24230df550e9880f4340fc6341c8f52 (patch) | |
tree | ab5d5e0944c68b7c30ae34daade8947dddee322c /sysdep/bsd | |
parent | 79e2293ab2abbd92bb3326a95759a4ca32d9af81 (diff) |
Kernel socket missing err_hook fix
Thanks to Tim Weippert for bugreport.
Diffstat (limited to 'sysdep/bsd')
-rw-r--r-- | sysdep/bsd/krt-sock.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sysdep/bsd/krt-sock.c b/sysdep/bsd/krt-sock.c index 6ff3b2b7..f2ae81c3 100644 --- a/sysdep/bsd/krt-sock.c +++ b/sysdep/bsd/krt-sock.c @@ -911,6 +911,12 @@ krt_sock_hook(sock *sk, int size UNUSED) return 0; } +static void +krt_sock_err_hook(sock *sk, int e UNUSED) +{ + krt_sock_hook(sk, 0); +} + static sock * krt_sock_open(pool *pool, void *data, int table_id) { @@ -932,6 +938,7 @@ krt_sock_open(pool *pool, void *data, int table_id) sk = sk_new(pool); sk->type = SK_MAGIC; sk->rx_hook = krt_sock_hook; + sk->err_hook = krt_sock_err_hook; sk->fd = fd; sk->data = data; |