[Xorg] Fixes for Kdrive composite exposures

Damien Ciabrini Damien.Ciabrini at sophia.inria.fr
Thu Aug 19 04:44:28 PDT 2004


I've found a problem with Kdrive handling of window exposures when
xcompmgr is running (ie in composite code). 

To reproduce the bug, start afterstep and then xcompmgr. when both are
loaded, simply start afterstep's background manager:
  asetroot 0 0 -l

This make Kdrive SIGBUS when it tries to repaint the root window.

The problem comes from the fact that asetroot make a call to
XCreateWindow with negatives position (IIRC x=-10000, y=-10000).
The server then try to redisplay the whole screen starting from the root
window. It computes the exposed regions to redisplay. 

The SIGBUS comes from the fact that when "Redirect to pixmap" is enable
(ie xcompmgr is running), some exposed regions contains negative values.
Note that without xcompmgr (thus without redirect to pixmap) regions
never contains negatives and thus Kdrive never segfaults.

Attached, you can find a simple fix to avoid negatives values in such
exposure regions. With this patch, the computation of exposed regions
returns exactly the same result whether "Redirect to pixmap" is enable
or not.

Can someone review the patch before it can be committed into the tree ?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: xserver-fix-composite-exposures.patch.gz
Type: application/x-gzip
Size: 781 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg/attachments/20040819/ec29ee86/attachment.bin>

More information about the xorg mailing list