diff options
author | Barbu Paul - Gheorghe <barbu.paul.gheorghe@gmail.com> | 2015-12-29 11:20:49 +0200 |
---|---|---|
committer | Michael Mann <mmann78@netscape.net> | 2015-12-30 00:07:47 +0000 |
commit | cef51084f2f2d5b23cd95a3c3eaa55dfc50fe2b4 (patch) | |
tree | 26fe4af8d091a8e04faa212d01a8f7eb39fd70aa /docbook | |
parent | d1b46d9d54ebd2b9217100edc5cf944bdeaca9e1 (diff) | |
download | wireshark-cef51084f2f2d5b23cd95a3c3eaa55dfc50fe2b4.tar.gz |
improved the developer documentation
* tvb_*_length mentioned in README.dissector
* fixed typos in README.dissector
* using stats_tree_register_plugin in the stats_tree examples both in README.stats_tree and the dev guide
* removed the version information and the #endif from the stats tree section in README.dissector
Change-Id: I27df0b5dfd66a7c0ac5b0fe1bdc882b3e9ffda74
Reviewed-on: https://code.wireshark.org/review/12908
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'docbook')
-rw-r--r-- | docbook/wsdg_src/WSDG_chapter_dissection.asciidoc | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/docbook/wsdg_src/WSDG_chapter_dissection.asciidoc b/docbook/wsdg_src/WSDG_chapter_dissection.asciidoc index 84b05240bd..f81f1eebed 100644 --- a/docbook/wsdg_src/WSDG_chapter_dissection.asciidoc +++ b/docbook/wsdg_src/WSDG_chapter_dissection.asciidoc @@ -1060,18 +1060,14 @@ Here is a mechanism to produce statistics from the above TAP interface. ---- /* register all http trees */ static void register_foo_stat_trees(void) { - stats_tree_register("foo", "foo", "Foo/Packet Types", + stats_tree_register_plugin("foo", "foo", "Foo/Packet Types", 0, foo_stats_tree_packet, foo_stats_tree_init, NULL); } -WS_DLL_PUBLIC_DEF const gchar version[] = "0.0"; - WS_DLL_PUBLIC_DEF void plugin_register_tap_listener(void) { register_foo_stat_trees(); } - -#endif ---- ==== @@ -1079,8 +1075,8 @@ Working from the bottom up, first the plugin interface entry point is defined, +plugin_register_tap_listener()+. This simply calls the initialisation function +register_foo_stat_trees()+. -This in turn calls the +stats_tree_register()+ function, which takes three -strings, and three functions. +This in turn calls the +stats_tree_register_plugin()+ function, which takes three +strings, an integer, and three callback functions. . This is the tap name that is registered. @@ -1088,6 +1084,8 @@ strings, and three functions. . The name of the stats module. A $$'/'$$ character can be used to make sub menus. +. Flags for per-packet callback + . The function that will called to generate the stats. . A function that can be called to initialise the stats data. |