[Xcb] [Patch] Fix some api docs

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


-----BEGIN PGP SIGNED MESSAGE-----
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?

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

iQEcBAEBCAAGBQJM59TUAAoJECLkKOvLj8sGLK8H/ik7FqzF6IVJcPAiO9ADVVW6
t+K93tzTGHvnAKtfmAfT4dR6e81OloWrSn5ERgaJWxKjM9SWdRb4YdexDS0jcH1P
EZKCiyhbxXIKp/W+stMjaJRRe0B5Ai78rkMguf+/TPvYF5+ujniu3XSCX0XqLCja
1N1G6bBz3vUcHPNd2/b9sY9DcRGkbv9bS/phKzs69h6qnpjYx66kb+z78jV5Mg5v
VYenuGXB0R6R4xcpar+td4vB8awT5prXtItPO2F4YPoNhX8kx3v5IlkjQPZpLWTg
Bm1rdjwULB69/D6lJNiLLQmpfun5MEQxgHfgvyj205egp/grMhdvtBQQNRGT9u4=
=3nsO
-----END PGP SIGNATURE-----
-------------- 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