some fixes including adding double quotes

This commit is contained in:
arcan1s
2014-08-12 22:58:13 +04:00
parent b65f761520
commit 3b1701f8b5
15 changed files with 207 additions and 29 deletions

View File

@ -29,12 +29,14 @@ TaskResult runTask(const QString cmd, const bool useSuid)
command.waitForFinished(-1);
r.exitCode = command.exitCode();
r.output = command.readAllStandardOutput();
r.error = command.readAllStandardError();
} else {
QProcess command;
command.start(cmd);
command.waitForFinished(-1);
r.exitCode = command.exitCode();
r.output = command.readAllStandardOutput();
r.error = command.readAllStandardError();
}
return r;

View File

@ -38,6 +38,7 @@ protected:
struct TaskResult
{
int exitCode;
QByteArray error;
QByteArray output;
};
TaskResult runTask(const QString cmd, const bool useSuid = true);