X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=utilities%2Fnlmon.c;h=b6396d50b9da8c89bfa864ac031db7864e59904d;hb=9d9a0a0452a957472b0f3a9c132aea19cfb4e568;hp=1fb3808085f3f1f1ae48ea76fe6df649c97bf1b5;hpb=2fe27d5ad27f3c7879ea696209bcf9702d9b7109;p=openvswitch diff --git a/utilities/nlmon.c b/utilities/nlmon.c index 1fb38080..b6396d50 100644 --- a/utilities/nlmon.c +++ b/utilities/nlmon.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2009, 2010 Nicira Networks. + * Copyright (c) 2009, 2010, 2011 Nicira Networks. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -45,11 +45,16 @@ main(int argc OVS_UNUSED, char *argv[]) set_program_name(argv[0]); vlog_set_levels(NULL, VLF_ANY_FACILITY, VLL_DBG); - error = nl_sock_create(NETLINK_ROUTE, RTNLGRP_LINK, 0, 0, &sock); + error = nl_sock_create(NETLINK_ROUTE, &sock); if (error) { ovs_fatal(error, "could not create rtnetlink socket"); } + error = nl_sock_join_mcgroup(sock, RTNLGRP_LINK); + if (error) { + ovs_fatal(error, "could not join RTNLGRP_LINK multicast group"); + } + for (;;) { struct ofpbuf *buf;