Ethereal-dev: Re: [Ethereal-dev] How To have tethereal -r - read from STDIN?

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

From: Guy Harris <guy@xxxxxxxxxx>
Date: Fri, 12 Jul 2002 18:36:59 -0700
On Fri, Jul 12, 2002 at 06:21:10PM -0700, Guy Harris wrote:
> You'd either have to disable those heuristics when reading from a
> non-seekable file, or do the "reading the same part of the file multiple
> times" with some form of internal buffering so that it only has to read
> the data once from the file.

And then you'd have to make the capture-file-reading code use that
internal buffering for the file type testing, as well; the way Ethereal
and Tethereal determine the type of file is to try opening it with open
routines for various capture file types until one succeeds, and that
also involves reading the same data in the file multiple times.