PATCH: kwallet lockup (#65978/#71048)

Lubos Lunak l.lunak at suse.cz
Thu Jan 8 14:38:15 GMT 2004


On Thursday 08 of January 2004 15:11, George Staikos wrote:
> On Thursday 08 January 2004 08:52, Lubos Lunak wrote:
> >  compile and run the attached testapp. And make sure you have option
> > AllowDeactivateGrabs in XF86Config, 'sleep 20;killall a.out' or similar
> > ready, or you'll have to use Ctrl+Alt+Backspace. #65978 has a good
> > analysis of the problem, let's go to the solution:
>
>     Yeah I was poking around with this problem recently too.  :(  Thanks
> for looking into it.

 I think I have a better version of the kapplication patch. This one closes 
the popup on the first keyboard event. It still eats the first keypress 
though. Avoiding would requite a lot of black magic I'm afraid, and I don't 
think it's worth trying it.

> >  BTW, I think that there can be still possibly some problems with kwallet
> > in kded, as it reenters the enter loop when it shows the dialogs. If,
> > while kded is recursed in the event loop and waiting for the dialog to be
> > handled, some other request comes, possibly again reentering the event
> > loop, the calls may get intermixed, with who knows what results. I think
> > code in kded, when it needs a dialog, should only show it, setup signals,
> > return to the event loop, and continue after it gets signal about the
> > dialog being handled.
>
>    Good idea, I'll try that in ASAP.  Meanwhile it does use transactions so
> I *think* it's safe already, but probably less clear.

 I don't find it that critical, we don't have anything else showing dialogs in 
kded now, do we? And I think I described it a bit wrong. If you use modal 
dialogs, then you have to answer them in the LIFO order, because the modality 
will block the previous ones - which might not be possibly always desired. 
That's why non-modal dialogs should be used, and control returned to event 
loop while they're shown. (Now that I think of it, there should not be the 
problem with reentering the event loop I described above, because modality 
blocks the sooner dialogs).

-- 
Lubos Lunak
KDE developer
---------------------------------------------------------------------
SuSE CR, s.r.o.  e-mail: l.lunak at suse.cz , l.lunak at kde.org
Drahobejlova 27  tel: +420 2 9654 2373
190 00 Praha 9   fax: +420 2 9654 2374
Czech Republic   http://www.suse.cz/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: kapplication.cpp.patch
Type: text/x-diff
Size: 1661 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20040108/b0711cb8/attachment.patch>


More information about the kde-core-devel mailing list