Danger Will Robinson: EnumDisplayDevices
Date: 1/12/2006
In the documentation for EnumDisplayDevices it tells you that you need to initialize the cb parameter of DISPLAY_DEVICE to sizeof(DISPLAY_DEVICE), fair enough. That part is obvious. In XP you can do that and then call EnumDisplayDevices multiple times with the same DISPLAY_DEVICE structure and it works as you'd expect. But in Win2k it overwrites the cb parameter with a new larger value with every call to EnumDisplayDevices, so the 2nd call overwrites the stack and your app goes kaboom!

So now you know.
Email (optional): (Will be HTML encoded to evade harvesting)
Remember username and/or email in a cookie.
Notify me of new posts in this thread via email.