Close write channel after writing to QProcess.
This commit is contained in:
parent
906a89c16d
commit
192305c1d5
|
@ -32,6 +32,7 @@ ActionReply ExternalCommandHelper::start(const QVariantMap& args)
|
||||||
cmd.setEnvironment(environment);
|
cmd.setEnvironment(environment);
|
||||||
cmd.start(command, arguments);
|
cmd.start(command, arguments);
|
||||||
cmd.write(input);
|
cmd.write(input);
|
||||||
|
cmd.closeWriteChannel();
|
||||||
cmd.waitForFinished(-1);
|
cmd.waitForFinished(-1);
|
||||||
QByteArray output = cmd.readAllStandardOutput();
|
QByteArray output = cmd.readAllStandardOutput();
|
||||||
reply.addData(QStringLiteral("output"), output);
|
reply.addData(QStringLiteral("output"), output);
|
||||||
|
|
Loading…
Reference in New Issue