From b8113220499fa8384bc2fbcc17aba59b636f2d48 Mon Sep 17 00:00:00 2001 From: Denis Dzyubenko Date: Tue, 5 Oct 2010 17:39:57 +0200 Subject: Fix copying large data to non-Qt applications In send_selection when we decide to use INCR properties we set the given property value to be INCR atom, however we were also sending SelectionNotify event containing the name of the property that the client should watch as INCR, which is wrong, we should send the original property that we were asked to use instead. This fixes copying large junks of data from Qt application, for example copying text (>200k) to gedit or images to gimp. Task-number: QTBUG-8644 Reviewed-by: Bradley T. Hughes (cherry picked from commit 62ee836fafe515c03b0be716585f8c2354e188f7) --- src/gui/kernel/qclipboard_x11.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/kernel/qclipboard_x11.cpp b/src/gui/kernel/qclipboard_x11.cpp index 999a7c1..682b249 100644 --- a/src/gui/kernel/qclipboard_x11.cpp +++ b/src/gui/kernel/qclipboard_x11.cpp @@ -838,7 +838,7 @@ static Atom send_selection(QClipboardData *d, Atom target, Window window, Atom p ATOM(INCR), 32, PropModeReplace, (uchar *) &bytes, 1); (void)new QClipboardINCRTransaction(window, property, atomFormat, dataFormat, data, increment); - return ATOM(INCR); + return property; } // make sure we can perform the XChangeProperty in a single request -- cgit v0.12