Wireshark mailing list archives

Proposed changes for using a hex integer to compare against single-byte range slices


From: Gilbert Ramirez <gram () alumni rice edu>
Date: Tue, 28 Feb 2012 15:03:36 -0800

Hi. I haven't committed anything to Wireshark in quite a while, so I wanted
to gently re-introduce myself into the community by requesting a code
review.

One of my colleagues at work noticed that it feels more natural to compare
a single-byte byte string against a hex integer starting with "0x" than
with just bare hex digits.

That is, instead of this:

wlan_mgt.cisco.ccx1.unknown[8] == 19

this is more natural:

wlan_mgt.cisco.ccx1.unknown[8] == 0x19

I have opened an enhancement bug at:
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6882

and attached a proposed diff to allow this.

Please let me know any feedback.

Thanks,

Gilbert
___________________________________________________________________________
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: