diff options
author | Ondrej Zajicek <santiago@crfreenet.org> | 2010-04-02 11:31:20 +0200 |
---|---|---|
committer | Ondrej Zajicek <santiago@crfreenet.org> | 2010-04-02 11:31:20 +0200 |
commit | bed417288e989c48a1362bb1177f436a2e2f9f4f (patch) | |
tree | 3fb727a0e2b0be0cfecef14f30b57134eeb3348b /sysdep/bsd | |
parent | 126683feeda03ffb5a4ce23611e59a4598382d49 (diff) |
Minor fixes to previous patches.
Diffstat (limited to 'sysdep/bsd')
-rw-r--r-- | sysdep/bsd/sysio.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/sysdep/bsd/sysio.h b/sysdep/bsd/sysio.h index 9ee4ade3..87c78fb3 100644 --- a/sysdep/bsd/sysio.h +++ b/sysdep/bsd/sysio.h @@ -150,18 +150,18 @@ sysio_process_rx_cmsgs(sock *s, struct msghdr *msg) // log(L_WARN "RX %I %d", s->laddr, s->lifindex); } - -void -sysio_prepare_tx_cmsgs(sock *s, struct msghdr *msg) +/* Unfortunately, IP_SENDSRCADDR does not work for raw IP sockets on BSD kernels */ +static void +sysio_prepare_tx_cmsgs(sock *s, struct msghdr *msg, void *cbuf, size_t cbuflen) { struct cmsghdr *cm; struct in_addr *sa; if (!(s->flags & SKF_LADDR_TX)) - { - msg->msg_controllen = 0; - return; - } + return; + + msg->msg_control = cbuf; + msg->msg_controllen = cbuflen; if (s->iface) { |