MCPcopy Create free account
hub / github.com/F-Stack/f-stack / filt_soempty

Function filt_soempty

freebsd/kern/uipc_socket.c:3894–3911  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3892}
3893
3894static int
3895filt_soempty(struct knote *kn, long hint)
3896{
3897 struct socket *so;
3898
3899 so = kn->kn_fp->f_data;
3900
3901 if (SOLISTENING(so))
3902 return (1);
3903
3904 SOCKBUF_LOCK_ASSERT(&so->so_snd);
3905 kn->kn_data = sbused(&so->so_snd);
3906
3907 if (kn->kn_data == 0)
3908 return (1);
3909 else
3910 return (0);
3911}
3912
3913int
3914socheckuid(struct socket *so, uid_t uid)

Callers

nothing calls this directly

Calls 1

sbusedFunction · 0.50

Tested by

no test coverage detected