Commit ef79c38e authored by Martin Wilck's avatar Martin Wilck Committed by Alexandre Julliard

Avoid segfault with overlapped WriteFile() calls.

parent 55f9b751
......@@ -1740,9 +1740,9 @@ static BOOL FILE_WriteFileEx(HANDLE hFile, LPCVOID buffer, DWORD bytesToWrite,
goto error;
}
ovp->async.ops = &fileio_async_ops;
ovp->async.ops = ( lpCompletionRoutine ? &fileio_async_ops : &fileio_nocomp_async_ops );
ovp->async.handle = hFile;
ovp->async.fd = FILE_GetUnixHandle( hFile, GENERIC_WRITE );
ovp->async.fd = fd;
ovp->async.type = ASYNC_TYPE_WRITE;
ovp->async.func = FILE_AsyncWriteService;
ovp->lpOverlapped = overlapped;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment