Ethereal-cvs: [Ethereal-cvs] rev 14882: /trunk/epan/dissectors/: packet-bittorrent.c

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

Date: Sat, 09 Jul 2005 00:44:46 GMT
User: guy
Date: 2005/07/08 07:44 PM

Log:
 Find the BitTorrent dissector immediately after registering it, and save
 the handle, rather than finding it every time we need it.
 
 Just make a guint8 array with the BitTorrent magic string length
 followed by the string, and use "tvb_memeql()" to test against that - it
 handles checking to make sure there's enough data in the tvbuff (if
 not, it returns -1 as a "no match" indication) and then checks all of
 the first 20 bytes in one operation.
 
 Clean up white space.

Directory: /trunk/epan/dissectors/
  Changes    Path                   Action
  +16 -15    packet-bittorrent.c    Modified



http://anonsvn.ethereal.com/viewcvs/viewcvs.py?rev=14882&view=rev