Hi.

Is the secondary thread using COM (or better, have you called
CoInitialize(ex) before using pcap_open() on that thread)?

WinPcap makes use of a COM component internally to capture from NdisWan
adapters, maybe the threading model used by WinPcap is incompatible with
yours.

Have a nice day
GV

----- Original Message ----- 
From: "Marc Wetzel" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, June 16, 2004 1:04 PM
Subject: Update: [WinPcap-users] Problems with 3.1b3 and opening
\Device\NPF_GenericNdisWanAdapter


>
> As I just found out, this ONLY happens if pcap_open is called from inside
a
> thread. If I use it only inside main all works as expected.
>
> Clueless...
>
> /Marc
>
> > -----Original Message-----
> > From: Marc Wetzel [mailto:[EMAIL PROTECTED]
> > Sent: Wednesday, June 16, 2004 12:08 PM
> > To: [EMAIL PROTECTED]
> > Subject: [WinPcap-users] Problems with 3.1b3 and opening
> > \Device\NPF_GenericNdisWanAdapter
> >
> > Hi,
> >
> > I have some problems opening the \Device\NPF_GenericNdisWanAdapter
> > Adapter.
> >
> > I tried to open it with pcap_open but also with pcap_open_live but it
> > fails
> > always with
> > Error: "Could not open adapter. System could not find the device."
> > (translated from german error-msg.)
> >
> > The passed device strings were retrieved by pcap_findalldevs(). As far
as
> > I
> > can see in my debugger,
> > The passed string looks ok.
> >
> > Some secondary information:
> > - All other (Ethernet-card) devices work as expected. I can open them,
and
> > all packets are delivered.
> > - Ethereal can open the device \Device\NPF_GenericNdisWanAdapter. Here
are
> > no problems.
> >
> > I also tried various other combinations as explained in the developer
> > documentation
> > I passed a pointer to null (to get the first device). => exception in
> > wpcap.dll
> > I passed rpcap://\Device\NPF_GenericNdisWanAdapter. => same error-msg.
as
> > without rpcap.
> >
> > I wonder what I can do wrong, if one device works and the other one
not???
> >
> > I'm using WindowsXP,SP1.
> >
> >
> > Thanks in advance
> >
> > Marc
> >
> >
> >
> > ==================================================================
> >  This is the WinPcap users list. It is archived at
> >  http://www.mail-archive.com/[EMAIL PROTECTED]/
> >
> >  To unsubscribe use
> >  mailto: [EMAIL PROTECTED]
> > ==================================================================
>
>
>
> ==================================================================
>  This is the WinPcap users list. It is archived at
>  http://www.mail-archive.com/[EMAIL PROTECTED]/
>
>  To unsubscribe use
>  mailto: [EMAIL PROTECTED]
> ==================================================================
>





==================================================================
 This is the WinPcap users list. It is archived at
 http://www.mail-archive.com/[EMAIL PROTECTED]/

 To unsubscribe use 
 mailto: [EMAIL PROTECTED]
==================================================================

Reply via email to