[PATCH xserver] glx: Erase glx client private before using

Keith Packard keithp at keithp.com
Thu Aug 3 18:45:13 UTC 2017


Peter Harris <pharris at opentext.com> writes:

>     _dixInitPrivates(devPrivates, privates, type);
>
> which in turn calls
>
>     memset(addr, '\0', global_keys[type].offset);

Thanks, I missed that. 

> I could easily be convinced that client structures are re-used; I
> haven't checked that path.

I don't think so; AllocNewConnection always calls NextAvailableClient
which always calls dixAllocateObjectWithPrivates. Now I'm mystified as
to how I saw this structure filled with garbage. Even if it were the
server client, which needs fixups during initialization, those paths all
make sure any private space is zeroed.

I think I should have written down what caused a crash that this patch
fixed...

-- 
-keith
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 832 bytes
Desc: not available
URL: <https://lists.x.org/archives/xorg-devel/attachments/20170803/8068401b/attachment.sig>


More information about the xorg-devel mailing list