Delete the rules process, not the Rulebook

Fixes crash when editing window rules.

BUG: 351177
REVIEW: 124693
This commit is contained in:
Martin Gräßlin 2015-08-11 08:36:36 +02:00
parent 252a3ca682
commit 8c884d92b3

View file

@ -998,7 +998,7 @@ void RuleBook::edit(AbstractClient* c, bool whole_app)
p->setArguments(args);
p->setProcessEnvironment(kwinApp()->processStartupEnvironment());
p->setProgram(QStringLiteral(KWIN_RULES_DIALOG_BIN));
connect(p, static_cast<void (QProcess::*)(int, QProcess::ExitStatus)>(&QProcess::finished), this, &QProcess::deleteLater);
connect(p, static_cast<void (QProcess::*)(int, QProcess::ExitStatus)>(&QProcess::finished), p, &QProcess::deleteLater);
connect(p, static_cast<void (QProcess::*)(QProcess::ProcessError)>(&QProcess::error), this,
[p] (QProcess::ProcessError e) {
if (e == QProcess::FailedToStart) {