[Interest] Return value from QProcess

Duane duane.hebert at group-upc.com
Wed Apr 6 16:47:39 CEST 2016

On 06/04/2016 10:39 AM, Konstantin Tokarev wrote:
> 06.04.2016, 17:36, "Duane" <duane.hebert at group-upc.com>:
>> Qt 5.3, on TinyCore Linux 5 and Fedora 23.
>> I'm currently using a call to std::system to load a module with insmod.
>>    This works but I would like to do it with QProcess.
> Why?

I want to wait for finished with a timeout.

>> This also works
>> but I can't seem to get the return value of the insmod call like I can
>> with std::system. Any suggestions?
> QProcess::exitCode()

This works in the sense that it returns 0 when there's no error but it 
doesn't seem to return the return value from insmod.  For example, 
insmod returns 4531 when the file is already loaded but 
QProcess::exitCode is 17.  I can rmmod module I guess.

More information about the Interest mailing list