Very strange: Process A started process B, B will fail to execute unzip command if A exited.
-
Process A start process B:
@
QStringList arguments;
...
QProcess::startDetached("ProcessB", arguments );
@
B execute unzip command:
@
QStringList arguments;
arguments<<source_zip_file;
arguments<<"-d";
arguments<<destination_path;
QProcess::execute("unzip", arguments );
@
But if I execute rm command, it will success.
@
QStringList args;
args<<"-drf";
args<<destination_path;
QProcess::execute("rm", args);
@
Any suggestion? Thanks! -
welcome to devnet
Did you also try to launch ProcessB with execute for unzip?
Note: I have added code wrappings to your post. Please "use code wrappings":http://developer.qt.nokia.com/wiki/ForumHelp#e3f82045ad0f480d3fb9e0ac2d58fb01 next time.
-
Processes form a tree, axing away one does hurt its children. There is little you can do about that.