summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2012-06-05 04:47:23 +0000
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2012-06-05 04:47:23 +0000
commit9d7168c4373f66fb5eb6b31296d7b954105f6bbf (patch)
tree1d78bbd95ea19ebffbd57fbddc03238324841d15
parentc04ad1c59b82f2a790523184c5775834013f41da (diff)
parent7f0c9d3f773154e1c068983c2b19cd2e755326c3 (diff)
Merge branch 'dde' into dde-clean
-rw-r--r--libbpf/bpf_impl.c2
-rw-r--r--libbpf/bpf_impl.h2
-rw-r--r--libmachdev/net.c4
3 files changed, 4 insertions, 4 deletions
diff --git a/libbpf/bpf_impl.c b/libbpf/bpf_impl.c
index b2dafd16..c8a250b0 100644
--- a/libbpf/bpf_impl.c
+++ b/libbpf/bpf_impl.c
@@ -45,6 +45,8 @@
#include "queue.h"
#include "util.h"
+static struct net_hash_header filter_hash_header[N_NET_HASH];
+
/*
* Execute the filter program starting at pc on the packet p
* wirelen is the length of the original packet
diff --git a/libbpf/bpf_impl.h b/libbpf/bpf_impl.h
index e611491f..9073fdac 100644
--- a/libbpf/bpf_impl.h
+++ b/libbpf/bpf_impl.h
@@ -134,7 +134,7 @@ struct net_hash_header {
int n_keys; /* zero if not used */
int ref_count; /* reference count */
net_hash_entry_t table[NET_HASH_SIZE];
-} filter_hash_header[N_NET_HASH];
+};
typedef struct net_hash_header *net_hash_header_t;
diff --git a/libmachdev/net.c b/libmachdev/net.c
index 606765f5..ed52f0e4 100644
--- a/libmachdev/net.c
+++ b/libmachdev/net.c
@@ -214,9 +214,7 @@ deliver_msg(struct net_rcv_msg *msg, if_filter_list_t *ifp)
0, MACH_PORT_NULL);
if (err != MACH_MSG_SUCCESS)
{
- mach_port_deallocate(mach_task_self (),
- ((mach_msg_header_t *)msg)->msgh_remote_port);
- return -1;
+ /* TODO: remove from filter */
}
}
}