tcpdump mailing list archives
Re: libpcap pcap_dumper_t: feature request
From: Craig Davison <craig () darkcalgary com>
Date: Fri, 17 Oct 2003 10:49:32 -0600 (MDT)
On Fri, 17 Oct 2003, Guy Harris wrote:
On Thu, Oct 16, 2003 at 07:20:10PM -0600, Craig Davison wrote:What do you think about adding a pcap_dump_fileno(pcap_dumper_t*) function that returns a FILE *,The name should probably be "pcap_dump_file()" (by analogy to "pcap_file()" and "pcap_fileno()").
You're absolutely right.
Given that, I might be inclined to have "pcap_dump_ex()", or something such as that, which could take a "char *errbuf" and fill in the buffer with an error string, or have a "pcap_dumper_t" be a structure with a "FILE *" and an error buffer in it and have a "pcap_dump_geterr()" routine.
The pcap_dump_geterr is also a good idea because it's consistent with pcap_geterr. Of course, pcap_dump (or pcap_dump_ex if you take that path) would have to return an int to indicate success or failure (currently pcap_dump is a void function). -- Craig Davison - This is the TCPDUMP workers list. It is archived at http://www.tcpdump.org/lists/workers/index.html To unsubscribe use mailto:tcpdump-workers-request () tcpdump org?body=unsubscribe
Current thread:
- libpcap pcap_dumper_t: feature request Craig Davison (Oct 16)
- Re: libpcap pcap_dumper_t: feature request Guy Harris (Oct 17)
- Re: libpcap pcap_dumper_t: feature request Craig Davison (Oct 17)
- Re: libpcap pcap_dumper_t: feature request Craig Davison (Oct 23)
- Re: libpcap pcap_dumper_t: feature request Guy Harris (Nov 03)
- Re: libpcap pcap_dumper_t: feature request Guy Harris (Nov 16)
- Re: libpcap pcap_dumper_t: feature request Guy Harris (Oct 17)