Jacek Caban : server: Remove IRP from device queue before terminating async.

Alexandre Julliard julliard at winehq.org
Tue May 28 15:06:51 CDT 2019


Module: wine
Branch: master
Commit: dc5421f9506da691dbc631fb319e8d10a0e22ce9
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=dc5421f9506da691dbc631fb319e8d10a0e22ce9

Author: Jacek Caban <jacek at codeweavers.com>
Date:   Tue May 28 14:09:59 2019 +0200

server: Remove IRP from device queue before terminating async.

Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 server/device.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/server/device.c b/server/device.c
index e123583..1cebc3b 100644
--- a/server/device.c
+++ b/server/device.c
@@ -378,6 +378,9 @@ static void set_irp_result( struct irp_call *irp, unsigned int status,
     iosb->out_size = min( iosb->out_size, out_size );
     if (iosb->out_size && !(iosb->out_data = memdup( out_data, iosb->out_size )))
         iosb->out_size = 0;
+
+    /* remove it from the device queue */
+    list_remove( &irp->dev_entry );
     irp->file = NULL;
     if (irp->async)
     {
@@ -388,8 +391,6 @@ static void set_irp_result( struct irp_call *irp, unsigned int status,
     }
     wake_up( &irp->obj, 0 );
 
-    /* remove it from the device queue */
-    list_remove( &irp->dev_entry );
     release_object( irp );  /* no longer on the device queue */
     release_object( file );
 }




More information about the wine-cvs mailing list