Ethereal-dev: Re: [Ethereal-dev] Introducing additional capture-stop capabilities

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

From: Guy Harris <gharris@xxxxxxxxx>
Date: Sat, 8 Sep 2001 20:16:09 -0700
On Wed, Aug 22, 2001 at 05:49:47PM +0200, Thomas Wittwer wrote:
> There are three new modules (capture_stop_conditions, conditions and
> ringbuffer).

"cnd_eval()" is a varargs function; however, if different conditions
require different argument lists, how is the caller to know what type of
argument list should be supplied?

The code that calls it currently knows that there are two separate stop
conditions, "cnd_stop_timeout", which takes no arguments, and
"cnd_stop_capturesize", which takes as an argument the number of bytes
written to the capture file so far.

This doesn't seem to allow new conditions to be added without the code
that calls "cnd_eval()" knowing about the new conditions; given that,
I'm not sure I see the benefit of the general mechanism that
"conditions.c" introduces.