diff options
author | Thomas Graf <tgraf@redhat.com> | 2012-04-21 12:14:11 +0200 |
---|---|---|
committer | Thomas Graf <tgraf@redhat.com> | 2012-04-21 12:14:11 +0200 |
commit | a143037fa37994270a3db7f7eb57f128c9f5b29a (patch) | |
tree | cb48c57cf2bcda89a4434eee543cb42d197681b1 /tests | |
parent | e34ed950bd9c8f0deccc3cae1ec473be751253ff (diff) | |
download | libnl-a143037fa37994270a3db7f7eb57f128c9f5b29a.tar.gz |
test-cache-mngr: Let the cache manager allocate the socket
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test-cache-mngr.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/tests/test-cache-mngr.c b/tests/test-cache-mngr.c index 2c917da..528ae18 100644 --- a/tests/test-cache-mngr.c +++ b/tests/test-cache-mngr.c @@ -32,13 +32,11 @@ int main(int argc, char *argv[]) { struct nl_cache_mngr *mngr; struct nl_cache *lc, *nc, *ac, *rc; - struct nl_sock *sock; int err; signal(SIGINT, sigint); - sock = nl_cli_alloc_socket(); - err = nl_cache_mngr_alloc(sock, NETLINK_ROUTE, NL_AUTO_PROVIDE, &mngr); + err = nl_cache_mngr_alloc(NULL, NETLINK_ROUTE, NL_AUTO_PROVIDE, &mngr); if (err < 0) nl_cli_fatal(err, "Unable to allocate cache manager: %s", nl_geterror(err)); @@ -67,7 +65,6 @@ int main(int argc, char *argv[]) } nl_cache_mngr_free(mngr); - nl_socket_free(sock); return 0; } |