MCPcopy Create free account
hub / github.com/MiniZinc/MiniZincIDE / terminate

Method terminate

MiniZincIDE/process.cpp:70–88  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

68}
69
70void Process::terminate()
71{
72 if (state() != QProcess::NotRunning) {
73#ifdef Q_OS_WIN
74 if (IsWindows8OrGreater()) {
75 TerminateJobObject(jobObject, EXIT_FAILURE);
76 } else {
77 // We can't use job objects in Windows 7, since MiniZinc already uses them
78 QProcess::kill();
79 }
80#else
81 ::killpg(processId(), SIGKILL);
82#endif
83 if (!waitForFinished(500)) {
84 kill();
85 waitForFinished();
86 }
87 }
88}
89
90void Process::sendInterrupt()
91{

Callers 7

~MainWindowMethod · 0.80
compileMethod · 0.80
runMethod · 0.80
startVisualisationMethod · 0.80
runMethod · 0.80
cancelMethod · 0.80

Calls 3

disconnectMethod · 0.80
elapsedMethod · 0.80
stopMethod · 0.45

Tested by

no test coverage detected