Bug 264219

Summary: Run CliInterface from the main thread
Product: [Applications] ark Reporter: Raphael Kubo da Costa <rakuco>
Component: generalAssignee: Elvis Angelaccio <elvis.angelaccio>
Status: RESOLVED MOVED    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: FreeBSD   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Raphael Kubo da Costa 2011-01-25 04:35:59 UTC
Version:           unspecified (using Devel) 
OS:                FreeBSD

We already use a QProcess in CliInterface, so there should be no reason for also running it from a separate thread.

Besides all the hell associated to running threaded code, it is unnecessary and causes problems with main loops such as the one in CliInterface::runProcess() -- if CliInterface::failOperation() is called (when a wrong password is entered in a header-protected file), KJob::emitResult() will end up being called somewhere in the call stack, and will terminate the auxiliary thread running our QProcess, finishing the event loop before the process is terminated correctly.

Reproducible: Always
Comment 1 Elvis Angelaccio 2016-03-06 20:01:40 UTC
I'm moving this one on phabricator, since it's a more adequate place for development tasks :)

Link: https://phabricator.kde.org/T1771