[Xcb] uninitialized byted when a connection is created

Jeremy Kolb jkolb at brandeis.edu
Sun May 15 15:42:49 PDT 2005

Jamey Sharp wrote:

> XCB has a handful of different valgrind warnings about uninitialized
> writes, because it doesn't initialize most padding bytes. Jim Gettys
> once pointed me at a claim, unsubstantiated as I recall, that
> compression ratios improve by zeroing those bytes. True or not, it would
> at least make valgrind happy...
> --Jamey

This actually popped up on #freedesktop the other day, someone wanted to 
know if xcb zeroed out the queue since ssh and others apparently benefit 
greatly.  I found this line in xcb_out.c:

memset(c->out.queue + c->out.queue_len + vector[i].iov_len, 0, 

Does that not accomplish this?  Later on Josh Triplett said
"jkolb: Yeah, XCB zeroes it out specicially because either jg or keithp 
specifically asked us to."

So... is it zeroed out or not?


More information about the xcb mailing list