Don't assign the return value to a member variable.

svn path=/trunk/KDE/kdebase/workspace/; revision=845784
This commit is contained in:
Luboš Luňák 2008-08-12 11:45:06 +00:00
parent 63b01aff5d
commit ff13bd5ed5

View file

@ -483,7 +483,7 @@ Pixmap Toplevel::createWindowPixmap()
assert( compositing()); assert( compositing());
grabXServer(); grabXServer();
KXErrorHandler err; KXErrorHandler err;
window_pix = XCompositeNameWindowPixmap( display(), frameId()); Pixmap pix = XCompositeNameWindowPixmap( display(), frameId());
// check that the received pixmap is valid and actually matches what we // check that the received pixmap is valid and actually matches what we
// know about the window (i.e. size) // know about the window (i.e. size)
XWindowAttributes attrs; XWindowAttributes attrs;
@ -492,11 +492,11 @@ Pixmap Toplevel::createWindowPixmap()
|| attrs.width != width() || attrs.height != height() || attrs.map_state != IsViewable ) || attrs.width != width() || attrs.height != height() || attrs.map_state != IsViewable )
{ {
kDebug( 1212 ) << "Creating window pixmap failed: " << this; kDebug( 1212 ) << "Creating window pixmap failed: " << this;
XFreePixmap( display(), window_pix ); XFreePixmap( display(), pix );
window_pix = None; pix = None;
} }
ungrabXServer(); ungrabXServer();
return window_pix; return pix;
#else #else
return None; return None;
#endif #endif