Wireshark mailing list archives

Re: [Wireshark-commits] rev 48633: /trunk/epan/ /trunk/epan/: value_string.c


From: Evan Huus <eapache () gmail com>
Date: Thu, 28 Mar 2013 18:10:33 -0400

On Thu, Mar 28, 2013 at 6:02 PM,  <eapache () wireshark org> wrote:
http://anonsvn.wireshark.org/viewvc/viewvc.cgi?view=rev&revision=48633

User: eapache
Date: 2013/03/28 03:02 PM

Log:
 Greatly clean up value_string.c
  - use consistent indentation and coding style
  - add modelines
  - replace some g_assert calls with DISSECTOR_ASSERT where it makes sense
  - group related functions together and simplify many comments by referring to
    the 'normal' value_string as the canonical version

Directory: /trunk/epan/
  Changes    Path              Action
  +366 -328  value_string.c    Modified

Tangential to this, does anybody know what the deal is with
decode_enumerated_bitfield() and decode_enumerated_bitfield_shifted()?
The first is called in exactly one place, the second not at all. They
return static buffers (which is odd, though not necessarily wrong,
perhaps they should be using packet-scope memory?), and while they
make use of value strings they don't seem immediately value-string
related.

The only one that is called is fairly short so I'm tempted to manually
inline that and drop both functions. At the very least they should
probably be moved to to_str.c (or somewhere else).

Thoughts?

Evan
___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev () wireshark org>
Archives:    http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
             mailto:wireshark-dev-request () wireshark org?subject=unsubscribe


Current thread: