That's the problem. Despite what the docs say, the completion routine isn't optional. If you set it to NULL, Windows will try and call it which will go bang. My comment about this has been at the bottom of the functions' MSDN page for about two years now. Guess they don't want to, or are unwilling to fix either the docs or the code.
All I'm doing in my file io code is calling ReadFileEx with the overlapped struct set, and no completion routine.
adeyblueMember Since 24 Dec 2008
Offline Last Active Jan 25 2013 11:00 AM