[cairo] [PATCH 1/2] xlib: Don't crash when swapping a 0-sized glyph

Adam Jackson ajax at redhat.com
Thu Nov 8 09:19:30 PST 2012

On 10/31/12 4:13 PM, Adam Jackson wrote:
> malloc(0) needn't return NULL, and on glibc, doesn't.  Then we encounter
> a loop of the form do { ... } while (--c), which doesn't do quite what
> you were hoping for when c is initially 0.
> Since there's nothing to swap in this case, just bomb out.

Bump.  Anything else I need to add here?

- ajax

More information about the cairo mailing list