aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-ipmi.c
AgeCommit message (Collapse)AuthorFilesLines
2015-02-04Convert val_to_str -> val_to_str_wmem.Michael Mann1-2/+4
This is mostly for GUI usage, but a few dissectors needed some "non-packet scope" conversions. val_to_str officially now uses wmem_packet_scope() Change-Id: Ic9413eeb3406d7a7683222b86709f3675d628d81 Reviewed-on: https://code.wireshark.org/review/6933 Reviewed-by: Michael Mann <mmann78@netscape.net> Petri-Dish: Michael Mann <mmann78@netscape.net> Reviewed-by: Evan Huus <eapache@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2015-01-08ep_<protocol>_port_to_display -> <protocol>_port_to_displayMichael Mann1-1/+1
Adjust any other ep_ related APIs related to the transition. Change-Id: I961b371c2c4bda557e0f1817705c27eef0dae66c Reviewed-on: https://code.wireshark.org/review/6388 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-12-23Deleting unnecessary #includes from dissectors.Martin Mathieson1-3/+0
Third batch (packet-icmpv6.c -> packet-mac-lte.c). Will look at cleaning up and committing script afterwards. Change-Id: Ib91e36ad200db01c3000605f6a7a21125b96a640 Reviewed-on: https://code.wireshark.org/review/6018 Petri-Dish: Martin Mathieson <martin.r.mathieson@googlemail.com> Reviewed-by: Martin Mathieson <martin.r.mathieson@googlemail.com>
2014-12-21Cleanup use of #includes in non-generated epan/dissector/*.cBill Meier1-1/+0
Specifically: - Set packet.h to be the first wireshark #include after config.h and "system" #includes. packet.h added as an #include in some cases when missing. - Remove some #includes included (directly/indirectly) in packet.h. E.g., glib.h. (Done only for those files including packet.h). - As needed, move "system" #includes to be after config.h and before wireshark #includes. - Rework various #include file specifications for consistency. - Misc. Change-Id: Ifaa1a14b50b69fbad38ea4838a49dfe595c54c95 Reviewed-on: https://code.wireshark.org/review/5923 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-08-10Eliminate proto_tree_add_text from some dissectors.Michael Mann1-23/+14
Other minor cleanup while in the neighborhood. Change-Id: Ib76f4a9f89b5933425760af0a980c6a549031b8f Reviewed-on: https://code.wireshark.org/review/3537 Petri-Dish: Michael Mann <mmann78@netscape.net> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-29proto_tree_add_subtree[_format]Michael Mann1-23/+8
Change-Id: I7e016f10fcfdc0523bf2fe8c11295c0334f7c332 Reviewed-on: https://code.wireshark.org/review/2694 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-17check for correct ftypeMartin Kaiser1-2/+4
Change-Id: I2274b97c74a845e6514e8acff136e55f721f11a8 Reviewed-on: https://code.wireshark.org/review/2354 Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2014-06-17make dissect_ipmi_cmd() staticMartin Kaiser1-1/+2
Change-Id: Ie494a52fa73f7b91bc65da1bc36516f799ef4967 Reviewed-on: https://code.wireshark.org/review/2353 Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
2014-06-17Initialize rq_hdr.sessionEvan Huus1-0/+2
Bug:10168 Change-Id: Ida4d82d102421152785ce680aa47bcb5cf8692f6 Reviewed-on: https://code.wireshark.org/review/2334 Reviewed-by: Dmitry Bazhenov <dima_b@pigeonpoint.com> Reviewed-by: Evan Huus <eapache@gmail.com>
2014-06-16Have ipmi "dissectors" register through the build process instead of "manually"Michael Mann1-18/+5
Change-Id: I6d6d32e8a1bc21dee9bf52b502e1a02e9511ecb2 Reviewed-on: https://code.wireshark.org/review/2253 Reviewed-by: Dmitry Bazhenov <dima_b@pigeonpoint.com> Reviewed-by: Evan Huus <eapache@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-16Convert more time_to_str functions to wmemEvan Huus1-1/+1
Change-Id: Ibaae0e79935dc62f12f713f2df5b57d0f3f799b9 Reviewed-on: https://code.wireshark.org/review/2254 Reviewed-by: Evan Huus <eapache@gmail.com>
2014-06-16Convert a bunch of time_to_str functions to wmemEvan Huus1-1/+1
Change-Id: I24fe3cc4a3589dadc4528a77fe7ff13d06b1a983 Reviewed-on: https://code.wireshark.org/review/2245 Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-15Fix warnings turning errors (also fixes buildbot)Joerg Mayer1-0/+6
These fixes are superficial. Michael: Please review and either remove the unneeded stuff or put in the correct use. Change-Id: I15e0f8c746af5bd76f57965ddcbf06d9e4ac80ca Reviewed-on: https://code.wireshark.org/review/2223 Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2014-06-15packet-ipmi-se.c : proto_tree_add_text -> something filterable.Michael Mann1-3/+8
Also did some minor cleanup noticed while doing the filter conversion Change-Id: Iea61b395c0eeb6fbcaac4c09964da2cb3cdccda5 Reviewed-on: https://code.wireshark.org/review/2184 Reviewed-by: Dmitry Bazhenov <dima_b@pigeonpoint.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-06IPMI trace dissector (without PCAP-dependent part).U-beauty\bdn1-605/+987
Added KCS and TMode protocol dissectors. Request/response logic has been revised. Saved request data logic has been revised. Added Get Message command response dissector. Added missing PICMG command dissectors. Added new PICMG command dissectors. Added new PPS OEM command entries. Added VITA 46.11 command dissectors. From: Bill Meier: - refs to value_strings/range_strings in hf[] entries, by convention, should use VALS/RVALS macros; - refs to true_false_strings should use TFS(&...) macro. also: true_false_string definitions should not be defined as arrays. - remove some unneeded #includes (packet-ipmi.c). - Do some re-indentation. - Add editor-modelines as needed. bug: 10004 Change-Id: Ib269b35784c0b70892d1e0111bcfb483ea64092c Reviewed-on: https://code.wireshark.org/review/1185 Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-06-03packet-ipmi...: Various cleanups:Bill Meier1-0/+13
- refs to value_strings in hf[] entries, by convention, should use VALS macro; - add editor-modelines as needed; Fix some indentation. Change-Id: Iaa0196bab6de066ed68a2755b69b07fadd33e498 Reviewed-on: https://code.wireshark.org/review/1927 Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-04-19More name changes.Guy Harris1-1/+1
Add ep_ to routines that may return ephemeral strings. Change "get_XXX" to "XXX_to_display" if the routine returns a formatted string if it can't get a name. Change-Id: Ia0e82784349752cf4285bf82788316c9588fdd88 Reviewed-on: https://code.wireshark.org/review/1217 Reviewed-by: Guy Harris <guy@alum.mit.edu>
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-19Rename more to_str functions to have ep_ in the name if they return ephemeralEvan Huus1-2/+2
buffers. Remove two unused functions. svn path=/trunk/; revision=54250
2013-12-14Fix warningsJakub Zawadzki1-4/+2
svn path=/trunk/; revision=54089
2013-09-16Convert proto_tree_add_uint_format to proto_tree_add_uint_format_value if ↵Michael Mann1-6/+6
hf_ field name is the first part of the formatted string. This was all manual inspection and most cases were either: 1. Case sensitivity differences between hf_ field name and formatted string. 2. Unnecessary whitespace between hf_ field name and colon in formatted string There are cases where the hf_ field name doesn't quite match the proto_tree_add_uint_format, but it's close enough that one of them should be "right", I'm just not sure which is, I just know the string in proto_tree_add_uint_format is the one displayed. svn path=/trunk/; revision=52098
2013-09-15Convert proto_tree_add_uint_format to proto_tree_add_uint_format_value if ↵Michael Mann1-6/+6
hf_ field name is the first part of the formatted string. This was done with a perl script on the dissectors directory (packet-*.c), followed by manual inspection of the output. The manual inspection yielded a few cases that really should have been proto_tree_add_uint or proto_tree_add_item, so I updated them accordingly. The script didn't catch as many as I would have liked, but it's a start. The most common (ab)use of proto_tree_add_uint_format was for appending strings to CRC/checksum values to note good or bad CRC/checksum. svn path=/trunk/; revision=52045
2013-08-31Convert another 10 dissectors to wmem.Evan Huus1-14/+13
svn path=/trunk/; revision=51612
2013-07-03Fix some Dead Store (Dead assignement/Dead increment) Warning found by ClangAlexis La Goutte1-1/+1
svn path=/trunk/; revision=50360
2013-05-03Remove global packet_info* current_pinfoMichael Mann1-27/+24
svn path=/trunk/; revision=49143
2013-03-29Rename value string (and similar) functions to use a consistent pattern. ThisEvan Huus1-1/+1
was done using textual search+replace, not anything syntax-aware, so presumably it got most comments as well (except where there were typos). Use a consistent coding style, and make proper use of the WS_DLL_* defines. Group the functions appropriately in the header. I ended up getting rid of most of the explanatory comments since many of them duplicated what was in the value_string.c file (and were out of sync with the recent updates I made to those in r48633). Presumably most of the comments should be in the .h file not the .c file, but there's enough churn ahead that it's not worth fixing yet. Part of https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8467 svn path=/trunk/; revision=48634
2013-03-18From beroset:Anders Broman1-11/+11
remove C++ incompatibilities https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8416 svn path=/trunk/; revision=48400
2012-09-20We always HAVE_CONFIG_H so don't bother checking whether we have it or not.Jeff Morriss1-2/+0
svn path=/trunk/; revision=45017
2012-08-10Use val_to_str_const() where appropriate;Bill Meier1-1/+1
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-05-04AFAICT sys/types.h & netinet/in.h #includes are not needed for these files.Bill Meier1-4/+1
(Let's see if any of the buildbots give any errors). Also: remove trailing whitespace on lines. svn path=/trunk/; revision=42429
2011-10-21For proto_tree_add_item(..., proto_xxx, ...)use ENC_NA as the encoding arg.Bill Meier1-1/+1
Also: remove trailing whitespace for a number of files. svn path=/trunk/; revision=39503
2011-10-06Convert 'encoding' parameter of certain proto_tree_add_item() calls in ↵Bill Meier1-6/+6
non-autogenerated epan/dissectors: Specifically: Replace FALSE|0 and TRUE|1 by ENC_BIG_ENDIAN|ENC_LITTLE_ENDIAN as the encoding parameter for proto_tree_add_item() calls which directly reference an item in hf[] which has a type of: FT_UINT8 FT_UINT16 FT_UINT24 FT_UINT32 FT_UINT64 FT_INT8 FT_INT16 FT_INT24 FT_INT32 FT_INT64 FT_FLOAT FT_DOUBLE svn path=/trunk/; revision=39288
2011-10-04Use ENC_NA as encoding for proto_tree_add_item() calls which directly ↵Bill Meier1-2/+2
reference an hf item (in hf[] with types: FT_NONE FT_BYTES FT_IPV6 FT_IPXNET FT_OID Note: Encoding field set to ENC_NA only if the field was previously TRUE|FALSE|ENC_LITTLE_ENDIAN|ENC_BIG_ENDIAN svn path=/trunk/; revision=39260
2010-07-26Fix potential infinite loop: for (guint8=0; guint8 < int; guint8++);Bill Meier1-2/+2
Fixes bug #5053. svn path=/trunk/; revision=33637
2010-05-21Have abs_time_to_str() and abs_time_to_str_secs() take an additionalGuy Harris1-1/+1
argument indicating whether to include the time zone in the string. If we're constructing a display filter, don't include the time zone, otherwise do. Fixes bug 4756. svn path=/trunk/; revision=32913
2010-05-13As suggested in ↵Jeff Morriss1-15/+8
http://www.wireshark.org/lists/wireshark-dev/200809/msg00075.html (as referenced in https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=2907 ) and https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=3411 : Write a new convenience routine for finding a conversation and, if it is not found, create it. The frame number and addresses are taken from pinfo (as is the common case). Use this function in a bunch of dissectors. svn path=/trunk/; revision=32790
2010-02-27Add a third date format, ABSOLUTE_TIME_DOY_UTC, to show UTC with theGuy Harris1-1/+1
date as YYYY/DDD, where DDD is a 1-origin day of year. Move the formats to a "time_fmt.h" file, included by the headers that use it. Have abs_time_to_str() and abs_time_secs_to_str() take the date format value, rather than a Boolean "show this as UTC" flag, as an argument. Document the ABSOLUTE_TIME_ formats a bit better. Use that format in the CCSDS and VCDU dissectors, rather than having those dissectors do the formatting themselves. svn path=/trunk/; revision=32034
2010-01-13From Didier Gautheron:Anders Broman1-4/+1
col_clear.diff Remove calls to col_clear : - called twice. - before functions which also clear the column - by replacing col_clear + col_append_xxx with col_add_xxx https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=4394 svn path=/trunk/; revision=31517
2009-12-10Show absolute times as UTC, as was done before.Guy Harris1-1/+1
svn path=/trunk/; revision=31228
2009-12-10Add an argument to abs_time_to_str() and abs_time_secs_to_str()Guy Harris1-1/+1
indicating whether the time should be shown as local time or UTC. For now, always pass FALSE, meaning "show as local time". Clean up some stuff in the SNMP dissector, use abs_time_secs_to_str() for times with one-second resolution, and update a comment in various macros in the WSP dissector, while we're at it. svn path=/trunk/; revision=31227
2009-12-10Use existing code to format relative and absolute times.Guy Harris1-13/+3
svn path=/trunk/; revision=31224
2009-12-10Fix Bug #4319: IPMI dissector crash (on Windows) displaying date/time;Bill Meier1-1/+1
Using strftime(..., "%F %T", ...) crashes on Windows (VC9) (!!); Use "%Y-%m-%d %H:%M:%S" instead..... svn path=/trunk/; revision=31223
2009-11-09Put type/length elements in correct subtree.Stig Bjørlykke1-2/+2
svn path=/trunk/; revision=30897
2009-08-09Don't guard col_set_str (COL_INFO/COL_PROTOCOL) with col_checkKovarththanan Rajaratnam1-3/+1
svn path=/trunk/; revision=29345
2009-07-07From Kovarththanan Rajaratnam:Stig Bjørlykke1-2/+2
More FT_XXX cleanup. svn path=/trunk/; revision=28971
2009-06-18From Kovarththanan Rajaratnam via bug 3548:Stig Bjørlykke1-18/+18
(1) Trailing/leading spaces are removed from 'name's/'blurb's (2) Duplicate 'blurb's are replaced with NULL (3) Empty ("") 'blurb's are replaced with NULL (4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME, FT_PROTOCOL, FT_STRING and FT_STRINGZ field types (5) Only allow non-zero value for 'display' if 'bitmask' is non-zero svn path=/trunk/; revision=28770
2009-04-08More ethereal --> wiresharkBill Meier1-1/+1
svn path=/trunk/; revision=27994
2008-08-07Put back the Intel URL for the IPMI specs.Guy Harris1-0/+6
svn path=/trunk/; revision=25952
2008-08-07Activate the IPMI changesAnders Broman1-5676/+1164
From Alexey Neyman. svn path=/trunk/; revision=25951
2007-10-27From Stephane Chazelas:Anders Broman1-7/+7
The description of the most significant bit of the "Device Revision" byte of the response to a "Get Device ID" is the wrong way round. 1 means "device provides Device SDRs" and not the contrary according to IPMI specs 1.5 and 2.0. Also, I noticed in that file that "Chassis" is spelled "Chasis". svn path=/trunk/; revision=23292