summaryrefslogtreecommitdiffstats
path: root/x11vnc/cleanup.c
diff options
context:
space:
mode:
Diffstat (limited to 'x11vnc/cleanup.c')
-rw-r--r--x11vnc/cleanup.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/x11vnc/cleanup.c b/x11vnc/cleanup.c
index e966d61..f41112d 100644
--- a/x11vnc/cleanup.c
+++ b/x11vnc/cleanup.c
@@ -122,6 +122,11 @@ void clean_up_exit (int ret) {
/* remove the shm areas: */
clean_shm(0);
+ stop_stunnel();
+ if (use_openssl) {
+ ssl_helper_pid(0, 0); /* killall */
+ }
+
if (! dpy) exit(ret); /* raw_rb hack */
/* X keyboard cleanups */
@@ -139,11 +144,6 @@ void clean_up_exit (int ret) {
if (use_solid_bg) {
solid_bg(1);
}
- stop_stunnel();
- if (use_openssl) {
- ssl_helper_pid(0, 0); /* killall */
- }
-
X_LOCK;
XTestDiscard_wr(dpy);
#if LIBVNCSERVER_HAVE_LIBXDAMAGE
OpenPOWER on IntegriCloud