diff options
| author | Michael Biebl <biebl@debian.org> | 2007-12-20 07:04:11 +0000 |
|---|---|---|
| committer | Michael Biebl <biebl@debian.org> | 2007-12-20 07:04:11 +0000 |
| commit | 8d8ad4577ac189e0173fe659fbecc3d2f267777c (patch) | |
| tree | 78d4917d4a1aa34402708fa3a89ad16d642e6d03 /debian/patches | |
| parent | 1468ebe109738f235b1a0e20725e8bae038dfb4a (diff) | |
- Bump Build-Depends on libnl-dev to (>= 1.0~pre8).
* debian/patches/24-libnl1-pre8_fix.patch - Backport support for libnl 1.0-pre8 from upstream SVN. git-svn-id: svn+ssh://svn.debian.org/svn/pkg-utopia/packages/unstable/networkmanager@1963 ceb527fc-18e6-0310-9fe2-813c157c29e7
Diffstat (limited to 'debian/patches')
| -rw-r--r-- | debian/patches/24-libnl1-pre8_fix.patch | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/debian/patches/24-libnl1-pre8_fix.patch b/debian/patches/24-libnl1-pre8_fix.patch new file mode 100644 index 00000000..26a54e7b --- /dev/null +++ b/debian/patches/24-libnl1-pre8_fix.patch @@ -0,0 +1,46 @@ +=== modified file 'src/NetworkManagerSystem.c' +--- src/NetworkManagerSystem.c 2007-12-20 06:06:27 +0000 ++++ src/NetworkManagerSystem.c 2007-12-20 06:57:47 +0000 +@@ -224,16 +224,33 @@ + + static struct nl_handle * new_nl_handle (void) + { +- struct nl_handle * nlh = NULL; +- +- nlh = nl_handle_alloc_nondefault(NL_CB_VERBOSE); +- nl_handle_set_pid (nlh, (pthread_self() << 16 | getpid())); +- if (nl_connect(nlh, NETLINK_ROUTE) < 0) +- { +- nm_warning ("%s: couldn't connecto to netlink: %s", __func__, nl_geterror()); ++ struct nl_handle * nlh = NULL; ++ struct nl_cb *cb; ++ ++ cb = nl_cb_alloc (NL_CB_VERBOSE); ++ nlh = nl_handle_alloc_cb (cb); ++ ++ if (!nlh) { ++ nm_warning ("couldn't allocate netlink handle."); ++ return NULL; ++ } ++ ++ if (nl_connect (nlh, NETLINK_ROUTE) < 0) { ++ /* HACK: try one more time. Because the netlink monitor for link state ++ * inits before we get here, it grabs the port that matches the PID ++ * of the NM process, which also happens to be the PID that libnl uses ++ * the first time too. The real fix is to convert nm-netlink-monitor.c ++ * over to use libnl. ++ */ + nl_handle_destroy (nlh); + nlh = NULL; +- } ++ ++ nlh = new_nl_handle (); ++ if (!nlh) { ++ nm_error ("couldn't connect to netlink: %s", nl_geterror ()); ++ return NULL; ++ } ++ } + + return nlh; + } + |