mirror of
https://github.com/FreeRDP/FreeRDP.git
synced 2024-12-04 15:23:32 +08:00
Correctly handling connection failure.
This commit is contained in:
parent
0c60fafebd
commit
4377c46bac
@ -265,7 +265,8 @@ int dfreerdp_run(freerdp* instance)
|
||||
memset(rfds, 0, sizeof(rfds));
|
||||
memset(wfds, 0, sizeof(wfds));
|
||||
|
||||
instance->Connect(instance);
|
||||
if (!instance->Connect(instance))
|
||||
return 0;
|
||||
|
||||
dfi = GET_DFI(instance);
|
||||
chanman = GET_CHANMAN(instance);
|
||||
|
@ -489,7 +489,8 @@ int xfreerdp_run(freerdp* instance)
|
||||
memset(rfds, 0, sizeof(rfds));
|
||||
memset(wfds, 0, sizeof(wfds));
|
||||
|
||||
instance->Connect(instance);
|
||||
if (!instance->Connect(instance))
|
||||
return 0;
|
||||
|
||||
xfi = GET_XFI(instance);
|
||||
chanman = GET_CHANMAN(instance);
|
||||
|
@ -35,7 +35,8 @@ boolean freerdp_connect(freerdp* instance)
|
||||
|
||||
IFCALL(instance->PreConnect, instance);
|
||||
status = rdp_client_connect((rdpRdp*) instance->rdp);
|
||||
IFCALL(instance->PostConnect, instance);
|
||||
if (status)
|
||||
IFCALL(instance->PostConnect, instance);
|
||||
|
||||
return status;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user