Why doesn’t my asynchronous read operation complete when I close the handle?

1 · Raymond Chen · July 30, 2021, 2:03 p.m.
A customer was using asynchronous I/O with an I/O completion port. At the time they wanted to shut things down, they still had an outstanding asynchronous read. To get things to clean up, they closed the file handle, expecting it to cause the Read­File to complete and fail with an error like ERROR_INVALID_HANDLE. The post Why doesn’t my asynchronous read operation complete when I close the handle? appeared first on The Old New Thing....