Jacek Caban : server: Use stored current kernel call to interpret IRP dispatch status.
Alexandre Julliard
julliard at winehq.org
Tue May 28 15:06:51 CDT 2019
Module: wine
Branch: master
Commit: dfe20465e894057d34da531fcd8a6e1fe4dfc310
URL: https://source.winehq.org/git/wine.git/?a=commit;h=dfe20465e894057d34da531fcd8a6e1fe4dfc310
Author: Jacek Caban <jacek at codeweavers.com>
Date: Tue May 28 14:09:22 2019 +0200
server: Use stored current kernel call to interpret IRP dispatch status.
Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
server/device.c | 14 ++++----------
1 file changed, 4 insertions(+), 10 deletions(-)
diff --git a/server/device.c b/server/device.c
index 1dcd500..d6ab1c5 100644
--- a/server/device.c
+++ b/server/device.c
@@ -884,20 +884,14 @@ DECL_HANDLER(get_next_device_request)
0, &device_manager_ops )))
return;
- if (req->prev)
- {
- if ((irp = (struct irp_call *)get_handle_obj( current->process, req->prev, 0, &irp_call_ops )))
- {
- set_irp_result( irp, req->status, NULL, 0, 0 );
- close_handle( current->process, req->prev ); /* avoid an extra round-trip for close */
- release_object( irp );
- }
- }
+ if (req->prev) close_handle( current->process, req->prev ); /* avoid an extra round-trip for close */
if (manager->current_call)
{
irp = manager->current_call;
- if (irp->async)
+ if (req->status)
+ set_irp_result( irp, req->status, NULL, 0, 0 );
+ else if (irp->async)
set_async_pending( irp->async, irp->file && is_fd_overlapped( irp->file->fd ) );
free_irp_params( irp );
release_object( irp );
More information about the wine-cvs
mailing list