[PATCH] Bugfix for "Pre-validate ChangeGC XIDs": off-by-one in loop index.

Jamey Sharp jamey at minilop.net
Fri May 14 12:21:33 PDT 2010


On Fri, May 14, 2010 at 12:15 PM, Jeremy Huddleston <jeremyhu at apple.com> wrote:
> Gah!  I'm an idiot.  I can't believe I spent over an hour debugging something because of confusing --i and i-- when editing gc.c

I still feel pretty dumb for letting the original patch go out with
the bug in it in the first place. ;-) Thanks for confirming that the
fix works.

> Do you have the malloc -> calloc change ready as well?

I sent it to the list a bit ago: "Device init: Don't crash when
CreateGC fails". That covers the crash due to ActivateDevice ignoring
errors, too. I tested it by replacing the malloc call in CreateGC with
a constant NULL.

Jamey


More information about the xorg-devel mailing list