Wireshark mailing list archives

Re: RFC: sorted value_string + bsearch


From: Anders Broman <anders.broman () ericsson com>
Date: Tue, 27 Apr 2010 14:39:21 +0200

Committed revision 32576. 

-----Original Message-----
From: wireshark-dev-bounces () wireshark org [mailto:wireshark-dev-bounces () wireshark org] On Behalf Of Jakub Zawadzki
Sent: den 27 april 2010 13:29
To: Developer support list for Wireshark
Subject: Re: [Wireshark-dev] RFC: sorted value_string + bsearch

On Tue, Apr 27, 2010 at 12:34:14PM +0200, Anders Broman wrote:
Committed revision 32574 to faciliate further testing, dockumentation 
updates will be needed if/when we are happy with the implementation.

Thx.

I have two changes in implementation :)
 - use function pointers instead of switch.
 - initalize ->match_type during first use of match_str() func.

I remove IS_INT_TYPE macro, cause it's now unused.

but it could be good idea to replace:
 (hfinfo->type == FT_UINT8 ||
  hfinfo->type == FT_UINT16 ||
  hfinfo->type == FT_UINT24 ||
  hfinfo->type == FT_UINT32 ||
  hfinfo->type == FT_UINT64 ||
  hfinfo->type == FT_INT8 ||
  hfinfo->type == FT_INT16 ||
  hfinfo->type == FT_INT24 ||
  hfinfo->type == FT_INT32 ||
  hfinfo->type == FT_INT64)

with single IS_[U]INT_TYPE...
___________________________________________________________________________
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: