Review Request 125314: KBuildSycocaProgressDialog: run kbuildsycoca5 with QProcess.

David Faure faure at kde.org
Sat Sep 19 20:10:19 UTC 2015



> On Sept. 19, 2015, 3:53 p.m., Albert Astals Cid wrote:
> > src/widgets/kbuildsycocaprogressdialog.cpp, line 59
> > <https://git.reviewboard.kde.org/r/125314/diff/1/?file=404752#file404752line59>
> >
> >     Can you close the dialog while the process is running? Does that destroy the process or does it continue? If it does continue does the lambda crash because dlg is gone? If it destroys the process is it something we care of the user should have just not closed the dialog?

Excellent point. I wanted to try this to see about reproducing bug 226732.
I tried and got it to crash ;)
QProcess dtor calls waitForFinished, which calls the slot, but d is already deleted. Ooops indeed.

Good catch, but your reasoning was slightly incorrect: if the dialog was fully deleted everything would be fine, the 3rd arg is &dlg so that it gets disconnected when dlg is destroyed.
The problem is that dlg is still alive (it's in ~QWidget), but d is not.

Q_PRIVATE_SLOT really works better with SIGNAL/SLOT....


- David


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/125314/#review85672
-----------------------------------------------------------


On Sept. 19, 2015, 3:05 p.m., David Faure wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/125314/
> -----------------------------------------------------------
> 
> (Updated Sept. 19, 2015, 3:05 p.m.)
> 
> 
> Review request for KDE Frameworks and Albert Astals Cid.
> 
> 
> Bugs: 166792
>     https://bugs.kde.org/show_bug.cgi?id=166792
> 
> 
> Repository: kio
> 
> 
> Description
> -------
> 
> The dbus-callback stuff from kded is unreliable and unnecessary.
> 
> And meanwhile I made kbuildsycoca5 work well when called more
> than once, the second instance will wait for the first one
> and then check if there's anything else to do, otherwise quit early.
> 
> Change-Id: I24f62cf1015bdbab1778245f4221f03f40a9bd0f
> BUGS: 235486, 166792
> FIXED-IN: 5.15
> 
> 
> Diffs
> -----
> 
>   src/widgets/kbuildsycocaprogressdialog.cpp 78d23dfda174f195e4c7fdfc1e128e83194326f3 
> 
> Diff: https://git.reviewboard.kde.org/r/125314/diff/
> 
> 
> Testing
> -------
> 
> kpropertiesdialogtest <path to app desktop file>, changing the comment, clicking OK.
> 
> 
> Thanks,
> 
> David Faure
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20150919/8fa9f51f/attachment-0001.html>


More information about the Kde-frameworks-devel mailing list