diff options
author | Kalle Viironen <kalle.viironen@digia.com> | 2014-11-14 14:49:21 +0200 |
---|---|---|
committer | Kalle Viironen <kalle.viironen@digia.com> | 2014-11-14 14:49:51 +0200 |
commit | fe76b7a6b182eb42a405f4b76bbabc6101f13f9a (patch) | |
tree | f7f2a90e30503d9be1456f3bc8c64451d077ef57 | |
parent | 22d4670b58dcb64a47ee589fbe922cb30a3e506c (diff) | |
parent | 1dbc31296d393bb542b0a99f7047dcb13aae3ce3 (diff) |
Merge branch 'stable' into dev
* stable:
Revert "Always create a process group and session"
Change copyright notice
Change-Id: I0ecba1dc7d5eb62bc4f757d3de6fa64aa60572d5
-rw-r--r-- | main.cpp | 8 | ||||
-rw-r--r-- | portlist.cpp | 4 | ||||
-rw-r--r-- | portlist.h | 4 | ||||
-rw-r--r-- | process.cpp | 10 | ||||
-rw-r--r-- | process.h | 4 |
5 files changed, 14 insertions, 16 deletions
@@ -2,7 +2,7 @@ ** ** Copyright (C) 2014 Digia Plc ** All rights reserved. -** For any questions to Digia, please use contact form at http://qt.digia.com +** For any questions to Digia, please use contact form at http://www.qt.io ** ** This file is part of QtEnterprise Embedded. ** @@ -12,7 +12,7 @@ ** a written agreement between you and Digia. ** ** If you have questions regarding the use of this file, please use -** contact form at http://qt.digia.com +** contact form at http://www.qt.io ** ****************************************************************************/ @@ -230,8 +230,6 @@ int main(int argc, char **argv) return 1; } - ::setpgid(0,0); // must be called before setsid() - ::setsid(); Config config = parseConfigFile(); while (!args.isEmpty()) { @@ -249,6 +247,8 @@ int main(int argc, char **argv) } } else if (arg == "--debug-gdb") { useGDB = true; + setpgid(0,0); // must be called before setsid() + setsid(); } else if (arg == "--debug-qml") { useQML = true; } else if (arg == "--stop") { diff --git a/portlist.cpp b/portlist.cpp index e0258c9..34488ef 100644 --- a/portlist.cpp +++ b/portlist.cpp @@ -2,7 +2,7 @@ ** ** Copyright (C) 2014 Digia Plc ** All rights reserved. -** For any questions to Digia, please use contact form at http://qt.digia.com +** For any questions to Digia, please use contact form at http://www.qt.io ** ** This file is part of QtEnterprise Embedded. ** @@ -12,7 +12,7 @@ ** a written agreement between you and Digia. ** ** If you have questions regarding the use of this file, please use -** contact form at http://qt.digia.com +** contact form at http://www.qt.io ** ****************************************************************************/ @@ -2,7 +2,7 @@ ** ** Copyright (C) 2014 Digia Plc ** All rights reserved. -** For any questions to Digia, please use contact form at http://qt.digia.com +** For any questions to Digia, please use contact form at http://www.qt.io ** ** This file is part of QtEnterprise Embedded. ** @@ -12,7 +12,7 @@ ** a written agreement between you and Digia. ** ** If you have questions regarding the use of this file, please use -** contact form at http://qt.digia.com +** contact form at http://www.qt.io ** ****************************************************************************/ diff --git a/process.cpp b/process.cpp index 0584ccf..b7e7342 100644 --- a/process.cpp +++ b/process.cpp @@ -2,7 +2,7 @@ ** ** Copyright (C) 2014 Digia Plc ** All rights reserved. -** For any questions to Digia, please use contact form at http://qt.digia.com +** For any questions to Digia, please use contact form at http://www.qt.io ** ** This file is part of QtEnterprise Embedded. ** @@ -12,7 +12,7 @@ ** a written agreement between you and Digia. ** ** If you have questions regarding the use of this file, please use -** contact form at http://qt.digia.com +** contact form at http://www.qt.io ** ****************************************************************************/ @@ -222,14 +222,12 @@ void Process::stop() if (kill(mDebuggee, SIGKILL) != 0) perror("Could not kill debugee"); } + if (kill(-getpid(), SIGTERM) != 0) + perror("Could not kill process group"); mProcess->terminate(); if (!mProcess->waitForFinished()) mProcess->kill(); - - // Just for completeness terminate the whole group - // in case the application has started subprocesses - ::kill(-getpid(), SIGTERM); } void Process::incomingConnection(int i) @@ -2,7 +2,7 @@ ** ** Copyright (C) 2014 Digia Plc ** All rights reserved. -** For any questions to Digia, please use contact form at http://qt.digia.com +** For any questions to Digia, please use contact form at http://www.qt.io ** ** This file is part of QtEnterprise Embedded. ** @@ -12,7 +12,7 @@ ** a written agreement between you and Digia. ** ** If you have questions regarding the use of this file, please use -** contact form at http://qt.digia.com +** contact form at http://www.qt.io ** ****************************************************************************/ |