Avoid crash when handling RDP error and xfreerdp quits.

Review Request #128569 - Created Aug. 1, 2016 and submitted

Information
Matthew Dawson
krdc
Applications/16.08
365054
Reviewers
kdeutils
uwolfer

If xfreerdp sent a failure message then quit, the RDP plugin would first
show a message box with a relevant message. During that time, the inner
event loop would handle the xfreerdp process quitting, which would signal
krdc to cleanup the RDP plugin's resources. When the message box event loop
completed, the RdpView would have been destroyed, causing a crash.

Now the RdpView signals that the view is quitting as soon as the message box
is shown, and avoids trying to quit twice if another part signals a quit.
Once the message box is dismissed, the process continues as normal. This
adds the necessary mechanisms to handle this, as well as moving the message
box display code to connectionError, to avoid some duplication.

BUG: 365054
REVIEW: 128569

I've listed the above bug, as I suspect it is part of this issue, but I'm not sure. I'll take out the reference if desired.

Before, when attempting a connection to an unreachable RDP server the app crashed after dismissing the dialogue box.

After, it no longer does. Everything appears to still clean up.

Urs Wolfer
Matthew Dawson
Review request changed

Status: Closed (submitted)

Change Summary:

Submitted with commit a6dca605fae01440cb510d65fd1896ba77646722 by Matthew Dawson to branch Applications/16.08.
Loading...