Yield in connection wait loops to reduce processor use.
Patch by Andrey Vasilkin on mailing list.
This commit is contained in:
parent
b08505cbe0
commit
f65b94ed84
@ -290,6 +290,8 @@ BOOL rdp_recv_deactivate_all(rdpRdp* rdp, wStream* s)
|
||||
|
||||
if (freerdp_shall_disconnect(rdp->instance))
|
||||
break;
|
||||
|
||||
SwitchToThread();
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
|
@ -336,6 +336,7 @@ BOOL rdp_client_connect(rdpRdp* rdp)
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
SwitchToThread();
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
|
Loading…
Reference in New Issue
Block a user