What is the data-type of pcap?

T

Tony Gahlinger

In reading up on raw socket programming under RedHat 9.2,
I come across 'typedef struct pcap pcap_t' in pcap.h.
Ok, so pcap_t is of type pcap, but I can't find any
include file that tells me what pcap is itself. Ideas,
anyone?

--Tony
 
B

Ben Pfaff

Tony Gahlinger said:
In reading up on raw socket programming under RedHat 9.2,
I come across 'typedef struct pcap pcap_t' in pcap.h.
Ok, so pcap_t is of type pcap, but I can't find any
include file that tells me what pcap is itself. Ideas,
anyone?

Quite possibly you're not supposed to know. `struct pcap' might
be defined only in the implementation of pcap, with its contents
supposed to be opaque to users.
 
J

Johan Lindh

Tony said:
In reading up on raw socket programming under RedHat 9.2,
I come across 'typedef struct pcap pcap_t' in pcap.h.
Ok, so pcap_t is of type pcap, but I can't find any
include file that tells me what pcap is itself. Ideas,
anyone?

--Tony

There's no requirement that struct pcap be defined, as long as there is
no attempt to use it's members or take it's size. If you need to find
out what it contains, try asking in a RedHat or Linux forum.
 
D

Default User

Tony said:
In reading up on raw socket programming under RedHat 9.2,
I come across 'typedef struct pcap pcap_t' in pcap.h.
Ok, so pcap_t is of type pcap, but I can't find any
include file that tells me what pcap is itself. Ideas,
anyone?


Your post is off-topic for comp.lang.c. Likely a linux newsgroup would
suit you. If pcap is a POSIX entity (and I don't recognize it at such)
then comp.unix.programmer would be useful.

Please visit:

http://www.csclub.uwaterloo.ca/u/dj3vande/clc/clc-welcome.txt
http://www.eskimo.com/~scs/C-faq/top.html
http://benpfaff.org/writings/clc/off-topic.html

for posting guidelines and frequently asked questions. Thank you.



Brian Rodenborn
 
M

Martin Dickopp

Tony Gahlinger said:
I come across 'typedef struct pcap pcap_t' in pcap.h.
Ok, so pcap_t is of type pcap,

No, `pcap_t' is of type `struct pcap'.

Martin
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,743
Messages
2,569,478
Members
44,898
Latest member
BlairH7607

Latest Threads

Top