aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-bacapp.c
AgeCommit message (Collapse)AuthorFilesLines
2014-07-06Squelch some compiler warnings.Guy Harris1-2/+7
Change-Id: Ie39c7b0c1fef8f862cec016a3a1a5bd1451a3df2 Reviewed-on: https://code.wireshark.org/review/2905 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-06-22Get rid of some unused variables.Guy Harris1-1/+0
Change-Id: I2a806af639e5f0519ba93b0048ec7a4624fa33fc Reviewed-on: https://code.wireshark.org/review/2567 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-06-22convert to proto_tree_add_subtree[_format]Michael Mann1-192/+116
Change-Id: Ib60ca75b7da8cfa21cfe2999c9b9448a02c332df Reviewed-on: https://code.wireshark.org/review/2560 Tested-by: Michael Mann <mmann78@netscape.net> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-19Use address_to_str(NULL, ...) for strings allocated outside dissectors.Guy Harris1-8/+32
ep_address_to_str() doesn't crash if called outside packet scope, but it's still not correct to use outside packet scope. Use address_to_str(NULL, ...) to allocate those strings, and then explicitly free them when we're done; exceptions don't get thrown between the allocate and free, so there's no risk of a leak. Change-Id: Iea2af93b0757e648d399e2ba64249224eb7e9e3c Reviewed-on: https://code.wireshark.org/review/2438 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-06-19Revert "Fixup: ep_address_to_str -> address_to_str"Michael Mann1-8/+8
Most (all?) of these functions are being called within GUI, so they can't have packet_scope, which is why they weren't already converted (I made this mistake once already) This reverts commit 7fea55a0541bcc5059f767970b6f6291f81d7b9c. Change-Id: I4bf29b206e5e1f5daefcec131309a8f6e78e1eb1 Reviewed-on: https://code.wireshark.org/review/2428 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-19Revert "Fixup: tvb_* -> tvb_captured"Michael Mann1-8/+8
https://www.wireshark.org/lists/wireshark-dev/201406/msg00131.html This reverts commit 246fe2ca4c67d8c98caa84e2f57694f6322e2f96. Change-Id: Ib24bae0198c13a84bd7f731bf4af921212109a8f Reviewed-on: https://code.wireshark.org/review/2430 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-18Fixup: ep_address_to_str -> address_to_strDario Lombardo1-8/+8
Change-Id: Id49ba07e32a71357b50b32de7cecfd80e412d508 Reviewed-on: https://code.wireshark.org/review/2379 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-18Fixup: tvb_* -> tvb_capturedDario Lombardo1-8/+8
Change-Id: I9209c1271967405c34c1b6fa43e1726a4d3a5a3f Reviewed-on: https://code.wireshark.org/review/2377 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-18Fixup: tvb_get_string(z) -> tvb_get_string(z)_encDario Lombardo1-2/+2
Change-Id: I63a3704effe3fcab01a193dc39b6a22e9f1cf3fe Reviewed-on: https://code.wireshark.org/review/2376 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-06Partly revert fdeed480bf89a1f43f7b3d4be67fa0e4333f7120Pascal Quantin1-8/+8
wmem_packet_scope() cannot be used outside of a packet treatment Change-Id: I6e545bbb51f325b366288f17358f9d2347a7d7c4 Reviewed-on: https://code.wireshark.org/review/977 Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-04-06Convert ep_address_to_str -> address_to_str(wmem_packet_scope, ...) for all ↵Michael Mann1-8/+8
dissectors Change-Id: I7489e2fb3a1f2630ca17b0a5fe1aa873992f1061 Reviewed-on: https://code.wireshark.org/review/975 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-03-04Remove all $Id$ from top of fileAlexis La Goutte1-2/+0
(Using sed : sed -i '/^ \* \$Id\$/,+1 d') Fix manually some typo (in export_object_dicom.c and crc16-plain.c) Change-Id: I4c1ae68d1c4afeace8cb195b53c715cf9e1227a8 Reviewed-on: https://code.wireshark.org/review/497 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2013-12-23Fix Dead Store (Dead assignement/Dead increment) warning found by ClangAlexis La Goutte1-1/+1
svn path=/trunk/; revision=54416
2013-12-23Fix Dead Store (Dead assignement/Dead increment) warning found by ClangAlexis La Goutte1-1/+1
svn path=/trunk/; revision=54412
2013-12-22Get rid of a set-but-unused variable.Guy Harris1-2/+1
svn path=/trunk/; revision=54355
2013-12-22Add UCS-4 support, and use it.Guy Harris1-82/+2
Shuffle the character ENC_ values around a bit, keeping the Unicode encodings together, moving the Windows code pages (only one for now) after the ISO 8859 encodings, and putting "I can't believe it's not ASCII!" at the end. Fix some comment typoes, and update another comment, while we're at it. svn path=/trunk/; revision=54351
2013-12-19Rename a couple of to_str functions to have ep_ in the name. This makes itEvan Huus1-2/+2
obvious that the returned string is ephemeral, and opens up the original names in the API for versions that take a wmem pool (and thus can work in any scope). svn path=/trunk/; revision=54249
2013-12-13Make sure all unused bits are 0 in bacapp, fixes uninitialized memory found byEvan Huus1-0/+1
valgrind. svn path=/trunk/; revision=54077
2013-12-13Note that apparently some BACnet implementations misuse the "ANSI X3.4"Guy Harris1-1/+3
encoding for ISO 8859-1; this means that those strings won't be correctly interpreted if they're interpreted as UTF-8. svn path=/trunk/; revision=54069
2013-12-08It's ISO 8859-1, not "ISO 18859-1", at least according to ANSI/ASHRAEGuy Harris1-21/+22
Standard 135-2004. Use tvb_get_string_enc() wherever possible. svn path=/trunk/; revision=53840
2013-11-23Remove old (2009) and no-longer-necessary compatibility macro.Evan Huus1-8/+8
svn path=/trunk/; revision=53527
2013-11-20Fix Bug #9457 Update BACnet vendor listJakub Zawadzki1-2/+12
Based on attachment #12139 (diff for adding the table) by rtsking117, but keep original formatting and encoding (ASCII). svn path=/trunk/; revision=53457
2013-11-09Include <epan/to_str.h> only when needed.Jakub Zawadzki1-0/+1
svn path=/trunk/; revision=53189
2013-10-23#if 0 numerous "unused const variables" (mostly value-string-arrays);Bill Meier1-2/+6
Also; fix a few "set but not used" warnings. svn path=/trunk/; revision=52780
2013-10-22Remove instances of unused 'data_handle' (and of one other handle).Bill Meier1-7/+0
svn path=/trunk/; revision=52767
2013-10-13Minor whitespace changesBill Meier1-907/+907
svn path=/trunk/; revision=52590
2013-09-22emem -> wmem conversion:Pascal Quantin1-1/+1
- ep_tvb_get_bits() -> wmem_packet_tvb_get_bits() - tvb_g_memdup()/ep_tvb_memdup() -> tvb_memdup() - tvb_fake_unicode()/tvb_get_ephemeral_faked_unicode() -> tvb_get_faked_unicode() - tvb_get_g_string()/tvb_get_ephemeral_string()/tvb_get_seasonal_string() -> tvb_get_string() - tvb_get_g_unicode_string()/tvb_get_ephemeral_unicode_string() -> tvb_get_unicode_string() - tvb_get_ephemeral_string_enc() -> tvb_get_string_enc() - update docs accordingly svn path=/trunk/; revision=52172
2013-09-17Reference 'BACnetVendorIdentifiers' value_string usingBill Meier1-2/+3
an extended value string. svn path=/trunk/; revision=52124
2013-09-17Update 'BACnetVendorIdentifiers' value strings fromBill Meier1-209/+370
BACnet vendor ID list dated September 16, 2013. http://www.bacnet.org/VendorID/BACnet%20Vendor%20IDs.htm svn path=/trunk/; revision=52119
2013-09-13Add comment where the vendor ids come fromJörg Mayer1-0/+4
svn path=/trunk/; revision=52014
2013-09-12Convert a few more dissectors to wmemPascal Quantin1-52/+63
svn path=/trunk/; revision=51991
2013-09-09expert_add_info_format_text -> expert_add_info_formatMichael Mann1-2/+2
svn path=/trunk/; revision=51852
2013-08-10Fix (-W)documentation error found by ClangAlexis La Goutte1-512/+509
packet-bacapp.c:78:13: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tvb ~~~~~~~~~^ packet-bacapp.c:79:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param pinfo ~~~~~~~~~~~^ packet-bacapp.c:80:14: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tree ~~~~~~~~~~^ packet-bacapp.c:100:13: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tvb ~~~~~~~~~^ packet-bacapp.c:101:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param pinfo ~~~~~~~~~~~^ packet-bacapp.c:102:14: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tree ~~~~~~~~~~^ packet-bacapp.c:103:16: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param offset ~~~~~~~~~~~~^ packet-bacapp.c:110:13: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tvb ~~~~~~~~~^ packet-bacapp.c:111:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param pinfo ~~~~~~~~~~~^ packet-bacapp.c:112:14: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tree ~~~~~~~~~~^ packet-bacapp.c:113:16: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param offset ~~~~~~~~~~~~^ packet-bacapp.c:130:13: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tvb ~~~~~~~~~^ packet-bacapp.c:131:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param pinfo ~~~~~~~~~~~^ packet-bacapp.c:132:14: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tree ~~~~~~~~~~^ packet-bacapp.c:133:16: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param offset ~~~~~~~~~~~~^ packet-bacapp.c:146:13: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tvb ~~~~~~~~~^ packet-bacapp.c:147:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param pinfo ~~~~~~~~~~~^ packet-bacapp.c:148:14: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param tree ~~~~~~~~~~^ packet-bacapp.c:149:16: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param offset ~~~~~~~~~~~~^ packet-bacapp.c:251:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param label ~~~~~~~~~~~^ packet-bacapp.c:263:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param label ~~~~~~~~~~~^ packet-bacapp.c:275:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param label ~~~~~~~~~~~^ packet-bacapp.c:288:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param label ~~~~~~~~~~~^ packet-bacapp.c:300:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param label ~~~~~~~~~~~^ packet-bacapp.c:325:24: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param service_choice ~~~~~~~~~~~~~~~~~~~~^ packet-bacapp.c:338:24: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param service_choice ~~~~~~~~~~~~~~~~~~~~^ packet-bacapp.c:521:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param label ~~~~~~~~~~~^ packet-bacapp.c:522:13: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param src ~~~~~~~~~^ packet-bacapp.c:521:11: error: parameter 'label' not found in the function declaration [-Werror,-Wdocumentation] * @param label ^~~~~ packet-bacapp.c:522:11: error: parameter 'src' not found in the function declaration [-Werror,-Wdocumentation] * @param src ^~~ packet-bacapp.c:654:11: error: parameter 'tree' not found in the function declaration [-Werror,-Wdocumentation] * @param tree the tree to append this item to ^~~~ packet-bacapp.c:654:11: note: did you mean 'subtree'? * @param tree the tree to append this item to ^~~~ subtree packet-bacapp.c:723:11: error: parameter 'tree' not found in the function declaration [-Werror,-Wdocumentation] * @param tree the tree to append this item to ^~~~ packet-bacapp.c:723:11: note: did you mean 'subtree'? * @param tree the tree to append this item to ^~~~ subtree packet-bacapp.c:749:11: error: parameter 'tree' not found in the function declaration [-Werror,-Wdocumentation] * @param tree the tree to append this item to ^~~~ packet-bacapp.c:749:11: note: did you mean 'subtree'? * @param tree the tree to append this item to ^~~~ subtree packet-bacapp.c:1076:24: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param service_choice ~~~~~~~~~~~~~~~~~~~~^ packet-bacapp.c:1266:17: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param service ~~~~~~~~~~~~~^ packet-bacapp.c:1337:4: error: unknown command tag name 'pram'; did you mean 'param'? [-Werror,-Wdocumentation] * @pram pinfo ^~~~~ param packet-bacapp.c:1337:14: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @pram pinfo ~~~~^ packet-bacapp.c:1366:15: error: empty paragraph passed to '@param' command [-Werror,-Wdocumentation] * @param label ~~~~~~~~~~~^ svn path=/trunk/; revision=51261
2013-07-17Remove fragment_data, add fragment_head, fragment_item - for now alias it to ↵Jakub Zawadzki1-1/+1
the same structure. This is begin of work to split fragment head and fragments items. svn path=/trunk/; revision=50708
2013-07-03expert_add_info_format_text + proto_tree_add_text = ↵Michael Mann1-8/+4
proto_tree_add_expert_format, where applicable. svn path=/trunk/; revision=50377
2013-06-30Batch of filterable expert infos.Michael Mann1-4/+14
Also added a note about deprecating expert_add_info_format svn path=/trunk/; revision=50270
2013-03-22Don't wire into the reassembly code the notion that reassemblies shouldGuy Harris1-8/+8
be done on flows from one address to another; reassembly for protocols running atop TCP should be done on flows from one TCP endpoint to another. We do this by: adding "reassembly table" as a data structure; associating hash tables for both in-progress reassemblies and completed reassemblies with that data structure (currently, not all reassemblies use the latter; they might keep completed reassemblies in the first table); having functions to create and destroy keys in that table; offering standard routines for doing address-based and address-and-port-based flow processing, so that dissectors not needing their own specialized flow processing can just use them. This fixes some mis-reassemblies of NIS YPSERV YPALL responses (where the second YPALL response is processed as if it were a continuation of a previous response between different endpoints, even though said response is already reassembled), and also allows the DCE RPC-specific stuff to be moved out of epan/reassembly.c into the DCE RPC dissector. svn path=/trunk/; revision=48491
2013-03-12- [-Wmissing-prototypes]Anders Broman1-4/+4
- explicit casts. svn path=/trunk/; revision=48265
2013-02-21Fix indent (Tab => 4 Spaces) Remove whitespace And Modelines infoAlexis La Goutte1-52/+65
svn path=/trunk/; revision=47800
2013-02-21Fix some Dead Store (Dead assignement/Dead increment) Warning found by ClangAlexis La Goutte1-7/+1
svn path=/trunk/; revision=47799
2013-02-15From Lori Tribble via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8331Evan Huus1-1/+1
Fix UCS-2 string decoding for strings longer than 127 characters. svn path=/trunk/; revision=47675
2013-02-09From Lori Tribble via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8306Evan Huus1-1/+6
Fix decoding the Loop Object Setpoint-Reference property in BACapp packets. svn path=/trunk/; revision=47577
2013-01-10From "schlephorst":Anders Broman1-10/+146
BACnet dissect new tags in NotificationParameters. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8181 svn path=/trunk/; revision=47011
2013-01-10From "schlephorst":Anders Broman1-5/+251
BACnet dissect new tags in EventParameters. https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8181 svn path=/trunk/; revision=47010
2012-12-26Fix a bunch of warnings.Guy Harris1-1/+1
Cast away some implicit 64-bit-to-32-bit conversion errors due to use of sizeof. Cast away some implicit 64-bit-to-32-bit conversion errors due to use of strtol() and strtoul(). Change some data types to avoid those implicit conversion warnings. When assigning a constant to a float, make sure the constant isn't a double, by appending "f" to the constant. Constify a bunch of variables, parameters, and return values to eliminate warnings due to strings being given const qualifiers. Cast away those warnings in some cases where an API we don't control forces us to do so. Enable a bunch of additional warnings by default. Note why at least some of the other warnings aren't enabled. randpkt.c and text2pcap.c are used to build programs, so they don't need to be in EXTRA_DIST. If the user specifies --enable-warnings-as-errors, add -Werror *even if the user specified --enable-extra-gcc-flags; assume they know what they're doing and are willing to have the compile fail due to the extra GCC warnings being treated as errors. svn path=/trunk/; revision=46748
2012-12-02Remove unneeded variable initializers.Evan Huus1-7/+6
svn path=/trunk/; revision=46328
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss1-3/+1
svn path=/trunk/; revision=45017
2012-09-07From Robert Bullen via ↵Jeff Morriss1-0/+2
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7683 : The reassembled fragments tree in the Packet Details view is awesome, but it lacks one thing: a field that exposes the reassembled data. tcp.data already exists for exposing a single TCP segment's payload as a byte array. It would be handy to have something similar for a single application layer PDU when TCP segment reassembly is involved. I propose tcp.reassembled.data, named and placed after the already existing field tcp.reassembled.length. My primary use case for this feature is outputting tcp.reassembled.data with tshark for further processing with a script. The attached patch implements this very feature. Because the reassembled fragment tree code is general purpose, i.e. not specific to just TCP, any dissector that relies upon it can add a similar field very cheaply. In that vein I've also implemented ip.reassembled.data and ipv6.reassembled.data, which expose reassembled fragment data as a single byte stream for IPv4 and IPv6, respectively. All other protocols that use the reassembly code have been left alone, other than inserting NULL into their initializer lists for the newly introduced struct field reassemble.h:fragment_items.hf_reassembled_data. svn path=/trunk/; revision=44802
2012-08-10Use val_to_str_const() where appropriate;Bill Meier1-46/+52
Also (for a few files): - create/use some extended value strings; - remove unneeded #include files; - remove unneeded variable initialization; - re-order fcns slightly so prefs_reg_handoff...() at end, etc svn path=/trunk/; revision=44438
2012-08-02From Lori Tribble via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7556 :Jeff Morriss1-11/+12
The BACnet GetEnrollmentSummary-ACK has an optional parameter Notification Class. The Wireshark decoding does not correctly decode when this parameter is missing. The fix is to verify the context exists before attempting to decode this parameter. From me: replace the few remaining tabs in the file with spaces. svn path=/trunk/; revision=44207