Subject: Re: Question about libpcap
To: Gerald Lee <email@example.com>
From: Darren Reed <firstname.lastname@example.org>
Date: 07/23/2007 23:39:26
Gerald Lee wrote:
> We have a unique situation. An engineer want to use libpcap to
> create compile a packet filter. However, he wants to use it purely in
> memory. The problem comes in that the application is threaded, and one
> of the other threads is blocked on stdin. This causes the parser to
> attempt to get more input from stdin. He tracked it down to the state
> of yyin, and would just as soon directly manipulate it. Others of us
> are discouraging this approach.
> However, I need to give him either 1) the appropriate
> incantations, or 2) a new interface (or variation on the current theme).
> We've tried things like pcap_compile_nocap, and still see the problem.
> Suggestions for either the correct usage (preferred), or
> suggestions for a name for a new entry point (even if we are the only
> ones using it ;).
This sounds like an application bug...
...perhaps an interaction problem if the lex/yacc code being
used by bpf is interacting incorrectly with lex/yacc used by
the application elsewhere?