L.Marvell
15th August 2006, 12:35
Have some question.
I start some command with Kdesu using QProcess.
QString program = "Kdesu";
QStringList arguments;
arguments << ...;
process->start(program, arguments);
How to terminate such process? If I do process->kill() it doesn't stop. AFAIU Kdesu starts command with root privileges, gets control to system and shuts down. Am I right?
The way I see is to find PID of running command and than process->("Kdesu", QStringList() << "-t" << "kill" << $pidOfCommand I didn't try it yet but I think it has to work. Maybe there is another/simpler method?
I start some command with Kdesu using QProcess.
QString program = "Kdesu";
QStringList arguments;
arguments << ...;
process->start(program, arguments);
How to terminate such process? If I do process->kill() it doesn't stop. AFAIU Kdesu starts command with root privileges, gets control to system and shuts down. Am I right?
The way I see is to find PID of running command and than process->("Kdesu", QStringList() << "-t" << "kill" << $pidOfCommand I didn't try it yet but I think it has to work. Maybe there is another/simpler method?