[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Re: [Bug 91357] klipper slows down KDE till nothing works anymore
From:       John Tapsell <john () geola ! co ! uk>
Date:       2005-02-22 10:05:52
Message-ID: 200502221005.52484.john () geola ! co ! uk
[Download RAW message or body]

hi,
  Can this be fixed by calling the disabling the clipboard before setting a 
selection?  Konqueror does this in some parts, but perhaps not all.

On Monday 21 February 2005 22:43, Esben Mose Hansen wrote:
> Hi,
>
> This bug is about Klipper and Konqueror slowing each other down. Most of it
> is fixed with a QT patch, but the bug is still there to lesser degree. Help
> in determining whether I should apply the attached patch would be
> appreciated. It is a ugly hack, but also an ugly bug with no easy solution.
>
> As I suspected, this bug is a conflict between Klipper and Konqueror, more
> specifically between the QClipboardWatcher class provided by QT. Unless
> there is more than one bug, of couse :)
>
> It seems that on mouse-up, Konqueror request the formats available on the
> selection or clipboard, concurrently with the selection being set. As
> Klipper also request the format available on the selection, they end up
> deadlocking with each other. I have back traces for interested parties :)
>
> I can see no easy fix for this as the problem lies in QT converting an
> asynchronous query to a synchronous. This cannot be done without blocking
> the X event queue. When two application uses this functionality, deadlock
> will ensue.
>
> I'm attaching a ugly hack <tm>. This works by delaying Klipper's collecting
> the clipboard contents for 30ms after the selection contents change. It
> fixes the problem, but might cause other subtle strangeness if anyone
> clicks fast enough, and if konqueror doesn't finish it's business before
> the 30ms, the bug will rear it's head again. Also, pure chance might cause
> this to occur anyway, and the latter goes with all QT programs.
>
> I will, of course, try fix this in a better way for KDE4, but for now, time
> is up.
>
> Thought and comments? Should I commit?
 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic