Catalli's threaded switch
[sliver-openvswitch.git] / ofproto / ofproto-sflow.c
index a96d8b4..c74c736 100644 (file)
 #include "sflow_api.h"
 #include "socket-util.h"
 #include "timeval.h"
-
-#define THIS_MODULE VLM_sflow
 #include "vlog.h"
 
+VLOG_DEFINE_THIS_MODULE(sflow)
+
 struct ofproto_sflow_port {
     struct netdev *netdev;      /* Underlying network device, for stats. */
     SFLDataSource_instance dsi; /* sFlow library's notion of port number. */
@@ -354,7 +354,7 @@ ofproto_sflow_del_port(struct ofproto_sflow *os, uint16_t odp_port)
         }
         netdev_close(osp->netdev);
         free(osp);
-        port_array_set(&os->ports, odp_port, NULL);
+        port_array_delete(&os->ports, odp_port);
     }
 }