[PATCH] os: Don't write the reply that overflows output buffer

Kristian Høgsberg krh at bitplanet.net
Wed Aug 4 06:33:32 PDT 2010

On Mon, Aug 2, 2010 at 2:36 PM, Keith Packard <keithp at keithp.com> wrote:
> On Mon,  2 Aug 2010 11:29:55 -0400, Kristian Høgsberg <krh at bitplanet.net> wrote:
>> Here's the other approach for fixing damage vs flush client.  In writing the
>> commit message, it certainly does feel like damage should just be fixed to
>> not reply on that behaviour.  And writing the patch, I realize that the
>> optimization is not just about saving a syscall, but also about avoiding
>> having to realloc the output buffer to hold a request that's bigger than
>> BUFSIZE (hello, XkbSendMap()).  The current code only does that when it
>> fails to write the output buffer + extra request and the remaining bytes
>> don't fit in a standard sized buffer.
> This doesn't really fix the issue as we're potentially sending a stream
> of events from the damage extension. We'd have to buffer all of them
> until FlushAllOutput, I think.

So from IRC it sounds like the post-op damage reporting code isn't too
horrible after all.  If you're OK with changing damageext to use the
post-op reporting, please add a Reviewed-by and I'll send a pull


More information about the xorg mailing list