[X2Go-Commits] [x2goclient] 107/139: pulsemanager.cpp: add Windows support to shutdown ().

git-admin at x2go.org git-admin at x2go.org
Wed Jan 13 18:42:19 CET 2016


This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch bugfix/osx
in repository x2goclient.

commit b22366a5f70b3a5a865fadc67916a9a378e626d8
Author: Mihai Moldovan <ionic at ionic.de>
Date:   Fri Oct 30 03:14:47 2015 +0100

    pulsemanager.cpp: add Windows support to shutdown ().
---
 debian/changelog     |    1 +
 src/pulsemanager.cpp |    7 +++++++
 2 files changed, 8 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index bdf5d98..22048a7 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -194,6 +194,7 @@ x2goclient (4.0.5.1-0x2go1) UNRELEASED; urgency=low
     - pulsemanager.cpp: make start () wrap the "real" OS-specific start
       functions.
     - pulsemanager.{cpp,h}: new function create_client_dir ().
+    - pulsemanager.cpp: add Windows support to shutdown ().
   * debian/control:
     - Change apache2-dev | libc6-dev build dependency back to apache2-dev
       only. Otherwise, apache2-dev is not installed at all, even though
diff --git a/src/pulsemanager.cpp b/src/pulsemanager.cpp
index f686dce..44b52f3 100644
--- a/src/pulsemanager.cpp
+++ b/src/pulsemanager.cpp
@@ -281,7 +281,14 @@ void PulseManager::shutdown () {
   connect (this,  SIGNAL (sig_pulse_server_terminated ()),
            &loop, SLOT (quit ()));
 
+  // Console applications without an event loop can only be terminated
+  // by QProcess::kill() on Windows (unless they handle WM_CLOSE, which
+  // PA obviously doesn't.)
+#ifdef Q_OS_WIN
+  pulse_server_->kill ();
+#else // defined (Q_OS_WIN)
   pulse_server_->terminate ();
+#endif // defined (Q_OS_WIN)
 
   loop.exec ();
 }

--
Alioth's /srv/git/code.x2go.org/x2goclient.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/x2goclient.git


More information about the x2go-commits mailing list