# This is a BitKeeper generated diff -Nru style patch. # # ChangeSet # 2004/11/15 08:58:09+01:00 kaber@coreworks.de # [SCTP]: Fix inetaddr notifier chain corruption # # Signed-off-by: Patrick McHardy # # net/sctp/protocol.c # 2004/11/15 08:58:03+01:00 kaber@coreworks.de +3 -3 # [SCTP]: Fix inetaddr notifier chain corruption # # Signed-off-by: Patrick McHardy # # net/sctp/ipv6.c # 2004/11/15 08:58:03+01:00 kaber@coreworks.de +6 -3 # [SCTP]: Fix inetaddr notifier chain corruption # # Signed-off-by: Patrick McHardy # diff -Nru a/net/sctp/ipv6.c b/net/sctp/ipv6.c --- a/net/sctp/ipv6.c 2004-11-15 08:58:42 +01:00 +++ b/net/sctp/ipv6.c 2004-11-15 08:58:42 +01:00 @@ -78,7 +78,10 @@ #include -extern struct notifier_block sctp_inetaddr_notifier; +extern int sctp_inetaddr_event(struct notifier_block *, unsigned long, void *); +static struct notifier_block sctp_inet6addr_notifier = { + .notifier_call = sctp_inetaddr_event, +}; /* ICMP error handler. */ void sctp_v6_err(struct sk_buff *skb, struct inet6_skb_parm *opt, @@ -983,7 +986,7 @@ sctp_register_af(&sctp_ipv6_specific); /* Register notifier for inet6 address additions/deletions. */ - register_inet6addr_notifier(&sctp_inetaddr_notifier); + register_inet6addr_notifier(&sctp_inet6addr_notifier); rc = 0; out: return rc; @@ -999,6 +1002,6 @@ inet6_del_protocol(&sctpv6_protocol, IPPROTO_SCTP); inet6_unregister_protosw(&sctpv6_seqpacket_protosw); inet6_unregister_protosw(&sctpv6_stream_protosw); - unregister_inet6addr_notifier(&sctp_inetaddr_notifier); + unregister_inet6addr_notifier(&sctp_inet6addr_notifier); sk_free_slab(&sctpv6_prot); } diff -Nru a/net/sctp/protocol.c b/net/sctp/protocol.c --- a/net/sctp/protocol.c 2004-11-15 08:58:42 +01:00 +++ b/net/sctp/protocol.c 2004-11-15 08:58:42 +01:00 @@ -622,8 +622,8 @@ /* Event handler for inet address addition/deletion events. * Basically, whenever there is an event, we re-build our local address list. */ -static int sctp_inetaddr_event(struct notifier_block *this, unsigned long ev, - void *ptr) +int sctp_inetaddr_event(struct notifier_block *this, unsigned long ev, + void *ptr) { unsigned long flags; @@ -824,7 +824,7 @@ }; /* Notifier for inetaddr addition/deletion events. */ -struct notifier_block sctp_inetaddr_notifier = { +static struct notifier_block sctp_inetaddr_notifier = { .notifier_call = sctp_inetaddr_event, };