[Xcb] [Patch] Fix some api docs

Uli Schlachter psychon at znc.in
Sat Nov 20 06:01:57 PST 2010

Hash: SHA256

Am 18.11.2010 07:02, Jamey Sharp wrote:
> On Wed, Nov 17, 2010 at 11:34 AM, Uli Schlachter <psychon at znc.in> wrote:
>> Sounds good. For the other brave souls who wander down that road, attached is a
>> patch which fixes/improves the docs for xcb_take_socket() and xcb_writev().
>> Hopefully the next one to find this issue won't have to read xcb's source code.
> I don't remember for sure, but I believe when we merged
> xcb_discard_reply, we decided not to implement support for discarding
> requests issued with xcb_writev. That's feasible but requires
> splitting list nodes in the pending_replies list. So unless I'm
> mistaken, at the moment neither of these patches is quite correct.
> I'd welcome either being told that xcb_discard_reply actually *does*
> work here, or getting a patch to make it work. :-)

I wrote the attached test app. According to valgrind, it doesn't leak memory.
When you remove the call to xcb_disconnect(c) at the end, it only leaks a
constant amount of memory (= it doesn't leak more memory if I send more
GetInputFocus requests). If I additionally remove the call to xcb_discard_reply,
a 3 MiB memory leak shows up.

I think I can tell you that you are wrong. ;)

So what do you think about the patch I sent in my last mail?

- -- 
Q: Because it reverses the logical flow of conversation.
A: Why is putting a reply at the top of the message frowned upon?
Version: GnuPG v1.4.10 (GNU/Linux)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: t.c
Type: text/x-csrc
Size: 931 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/xcb/attachments/20101120/49471099/attachment.c>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: t.c.sig
Type: application/octet-stream
Size: 287 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/xcb/attachments/20101120/49471099/attachment.obj>

More information about the Xcb mailing list