Ethereal-cvs: [ethereal-cvs] cvs commit: ethereal/wiretap ngsniffer.c wtap-int.h

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

From: Guy Harris <guy@xxxxxxxxxxxx>
Date: Fri, 11 Aug 2000 02:28:19 -0500 (CDT)
guy         2000/08/11 02:28:16 CDT

  Modified files:
    wiretap              ngsniffer.c wtap-int.h 
  Log:
  If we have a random stream open for a compressed Sniffer file, have the
  sequential pass through the file build a list of information about the
  compressed blobs, with the starting offset in the compressed file and in
  the uncompressed byte stream for each blob.
  
  When seeking on the random stream, check whether the target location is
  within the uncompressed buffer we currently have; if not, use that list
  to figure out which blob contains the target location, and read that
  blob into the buffer.  Then, as we now know that the target location is
  within the uncompressed buffer we currently have, just move the current
  pointer into that buffer to the target location.
  
  This means we don't have to read forwards through any uninteresting
  blobs in order to seek forwards, and don't have to go all the way back
  to the beginning and seek forwards in order to seek backwards.
  
  Revision  Changes    Path
  1.48      +344 -167  ethereal/wiretap/ngsniffer.c
  1.5       +9 -6      ethereal/wiretap/wtap-int.h