ifpps: Rename cpu number parameter to stats_top()
[netsniff-ng.git] / dissector_80211.c
blobf3d8b622a8765c70c2b67694e164076f392d7dbd
1 /*
2 * netsniff-ng - the packet sniffing beast
3 * Copyright 2009, 2010 Daniel Borkmann.
4 * Subject to the GPL, version 2.
5 */
7 #include <stdint.h>
9 #include "hash.h"
10 #include "protos.h"
11 #include "pkt_buff.h"
12 #include "dissector.h"
13 #include "dissector_80211.h"
14 #include "xmalloc.h"
15 #include "oui.h"
17 struct hash_table ieee80211_lay2;
19 #ifdef __WITH_PROTOS
20 static inline void dissector_init_entry(int type)
22 dissector_set_print_type(&ieee80211_ops, type);
25 static inline void dissector_init_exit(int type)
27 dissector_set_print_type(&none_ops, type);
30 static void dissector_init_layer_2(int type)
32 init_hash(&ieee80211_lay2);
33 // INSERT_HASH_PROTOS(blubber_ops, ieee80211_lay2);
34 for_each_hash_int(&ieee80211_lay2, dissector_set_print_type, type);
36 #else
37 static inline void dissector_init_entry(int type) {}
38 static inline void dissector_init_exit(int type) {}
39 static void dissector_init_layer_2(int type) {}
40 #endif /* __WITH_PROTOS */
42 void dissector_init_ieee80211(int fnttype)
44 dissector_init_entry(fnttype);
45 dissector_init_layer_2(fnttype);
46 dissector_init_exit(fnttype);
47 dissector_init_oui();
50 void dissector_cleanup_ieee80211(void)
52 free_hash(&ieee80211_lay2);
53 dissector_cleanup_oui();