1 |
swegener 11/01/23 20:24:45 |
2 |
|
3 |
Added: |
4 |
netlink-request-all-matches-when-requesting-interface.patch |
5 |
Log: |
6 |
Add bugfix patch to support kernels >=2.6.38, bug #352070. |
7 |
|
8 |
(Portage version: 2.2.0_alpha18/cvs/Linux x86_64) |
9 |
|
10 |
Revision Changes Path |
11 |
1.1 net-dns/avahi/files/netlink-request-all-matches-when-requesting-interface.patch |
12 |
|
13 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-dns/avahi/files/netlink-request-all-matches-when-requesting-interface.patch?rev=1.1&view=markup |
14 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-dns/avahi/files/netlink-request-all-matches-when-requesting-interface.patch?rev=1.1&content-type=text/plain |
15 |
|
16 |
Index: netlink-request-all-matches-when-requesting-interface.patch |
17 |
=================================================================== |
18 |
From 882da7d7385e51024bc64a08a21cfd86cc55f3d1 Mon Sep 17 00:00:00 2001 |
19 |
From: Andy Whitcroft <apw@×××××××××.com> |
20 |
Date: Tue, 18 Jan 2011 10:30:58 +0000 |
21 |
Subject: [PATCH] netlink: request all matches when requesting interface and address lists |
22 |
|
23 |
When requesting the a full list of interfaces and addresses for the machine |
24 |
avahi uses a wild card netlink search. This is done via a NLM_F_ROOT |
25 |
request. However we do not correctly request NLM_F_MATCH indicating |
26 |
we want all matches. This leads to the requests returning EINVAL on |
27 |
v2.6.38-rc1 and later kernels and to the daemon hanging during startup. |
28 |
|
29 |
Prior to v2.6.38-rc1 bugs in the kernel caused NLM_F_ROOT to incorrectly |
30 |
imply NLM_F_MATCH, see the commit below for details: |
31 |
|
32 |
commit 0ab03c2b1478f2438d2c80204f7fef65b1bca9cf |
33 |
Author: Jan Engelhardt <jengelh@×××××××.de> |
34 |
Date: Fri Jan 7 03:15:05 2011 +0000 |
35 |
|
36 |
netlink: test for all flags of the NLM_F_DUMP composite |
37 |
|
38 |
Add the missing NLM_F_MATCH. |
39 |
|
40 |
Signed-off-by: Andy Whitcroft <apw@×××××××××.com> |
41 |
--- |
42 |
avahi-core/iface-linux.c | 2 +- |
43 |
1 files changed, 1 insertions(+), 1 deletions(-) |
44 |
|
45 |
diff --git a/avahi-core/iface-linux.c b/avahi-core/iface-linux.c |
46 |
index a1b7f73..9a0bbb6 100644 |
47 |
--- a/avahi-core/iface-linux.c |
48 |
+++ b/avahi-core/iface-linux.c |
49 |
@@ -53,7 +53,7 @@ static int netlink_list_items(AvahiNetlink *nl, uint16_t type, unsigned *ret_seq |
50 |
n = (struct nlmsghdr*) req; |
51 |
n->nlmsg_len = NLMSG_LENGTH(sizeof(struct rtgenmsg)); |
52 |
n->nlmsg_type = type; |
53 |
- n->nlmsg_flags = NLM_F_ROOT|NLM_F_REQUEST; |
54 |
+ n->nlmsg_flags = NLM_F_MATCH|NLM_F_ROOT|NLM_F_REQUEST; |
55 |
n->nlmsg_pid = 0; |
56 |
|
57 |
gen = NLMSG_DATA(n); |
58 |
-- |
59 |
1.7.1 |