| 1802 | } |
| 1803 | |
| 1804 | int |
| 1805 | sosend(struct socket *so, struct sockaddr *addr, struct uio *uio, |
| 1806 | struct mbuf *top, struct mbuf *control, int flags, struct thread *td) |
| 1807 | { |
| 1808 | int error; |
| 1809 | |
| 1810 | CURVNET_SET(so->so_vnet); |
| 1811 | if (!SOLISTENING(so)) |
| 1812 | error = so->so_proto->pr_usrreqs->pru_sosend(so, addr, uio, |
| 1813 | top, control, flags, td); |
| 1814 | else { |
| 1815 | m_freem(top); |
| 1816 | m_freem(control); |
| 1817 | error = ENOTCONN; |
| 1818 | } |
| 1819 | CURVNET_RESTORE(); |
| 1820 | return (error); |
| 1821 | } |
| 1822 | |
| 1823 | /* |
| 1824 | * The part of soreceive() that implements reading non-inline out-of-band |
no test coverage detected