Re: GetAdapapters info asking for a wrong-size buffer?



Am 23.06.2005 18:53:00 schrieb villiros@xxxxxxxxx:

> Ok, but the buffer requested is smaller than the barebones structure.
> To contain two structures, it should be at least 2 *
> sizeof(IP_ADAPTER_INFO), yet it is 2 * 8 bytes smaller than that.

You have a structure packing problem somewhere. On my setup,
sizeof(IP_ADAPTER_INFO) is 640. Make sure you don't have #pragma pack
hidden somewhere or altered structure alignment in project settings.
Default alignment in MS compilers is 8 bytes, as in my setup.

--
Ralf.
.



Relevant Pages


Loading