DragonFly BSD
DragonFly commits List (threaded) for 2013-05
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

git: DragonFly_RELEASE_3_4 udp: Fix IP source address setting for multicast address bound socket (2)


From: Sepherosa Ziehau <sephe@xxxxxxxxxxxxxxxxxxxxxxx>
Date: Wed, 22 May 2013 22:40:42 -0700 (PDT)

commit 2a7aa965f0e1e9c424cfcf9fa83130f0045556b6
Author: Sepherosa Ziehau <sephe@dragonflybsd.org>
Date:   Thu May 23 13:35:07 2013 +0800

    udp: Fix IP source address setting for multicast address bound socket (2)
    
    Source address should _not_ be set to INADDR_ANY in udp_output(), which
    will make udp_output() calculate wrong pseudo header checksum.  Instead
    of letting IP to select the source address, we extend in_pcbladdr() to
    always locate the laddr, and use this function to find the source address
    in udp_output().

Summary of changes:
 sys/netinet/in_pcb.c     | 14 +++++++++++---
 sys/netinet/in_pcb.h     |  2 ++
 sys/netinet/udp_usrreq.c | 11 +++++------
 3 files changed, 18 insertions(+), 9 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/2a7aa965f0e1e9c424cfcf9fa83130f0045556b6


-- 
DragonFly BSD source repository



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]