[Winpcap-users] Problem with pcap_findalldevs while debugging myapp.

Антон Иванов anthony_johnson at mail.ru
Wed Aug 20 10:09:31 GMT 2008


Hi!
I create a dialog based application.
In OnInitDialog() function I try to get NIC information:
        ...
        // TODO: Add extra initialization here
        pcap_if_t *alldevs;
        pcap_if_t *d;
	char errbuf[PCAP_ERRBUF_SIZE];

	if (pcap_findalldevs(&alldevs, errbuf) == -1)
	{
		...
	}
        ...
Here occur the access violation error.
In call stack I have only NDISNPP! 58214d4f(). So I don't know what is my app doing here. :-)
In disassembly window:
       58214D4F   cmp         dword ptr [eax+ecx*4+18h],0
Registers:

     EAX = 00000000 EBX = 00000000
     ECX = 7FF55FFB EDX = 5821E464
     ESI = 0012BEF8 EDI = 000000B0
     EIP = 58214D4F ESP = 01FEFFB8
     EBP = 01FEFFEC EFL = 00000246 CS = 001B
     DS = 0023 ES = 0023 SS = 0023 FS = 003B
     GS = 0000 OV=0 UP=0 EI=1 PL=0 ZR=1 AC=0
     PE=1 CY=0

     FFD58004 = ????????

That's all I have after "if (pcap_findalldevs(&alldevs, errbuf) == -1)" string.
It happens on PC and notebook (Windows XP Professional SP2, NDISNPP.DLL has version 5.1.2600.2180, Winpcap version is 4.0.2 on both).
PC and notebook has one NIC.
I don't use COM/OLE.
Thanks!


More information about the Winpcap-users mailing list