gfx/cairo/ignore-rank0.patch

Thu, 15 Jan 2015 21:03:48 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Thu, 15 Jan 2015 21:03:48 +0100
branch
TOR_BUG_9701
changeset 11
deefc01c0e14
permissions
-rw-r--r--

Integrate friendly tips from Tor colleagues to make (or not) 4.5 alpha 3;
This includes removal of overloaded (but unused) methods, and addition of
a overlooked call to DataStruct::SetData(nsISupports, uint32_t, bool.)

     1 diff --git a/gfx/cairo/cairo/src/cairo-gstate.c b/gfx/cairo/cairo/src/cairo-gstate.c
     2 index 0439bcf..32a5c4b 100644
     3 --- a/gfx/cairo/cairo/src/cairo-gstate.c
     4 +++ b/gfx/cairo/cairo/src/cairo-gstate.c
     5 @@ -1271,8 +1271,13 @@ _cairo_gstate_set_font_matrix (cairo_gstate_t	    *gstate,
     6      if (memcmp (matrix, &gstate->font_matrix, sizeof (cairo_matrix_t)) == 0)
     7  	return CAIRO_STATUS_SUCCESS;
     9 -    if (! _cairo_matrix_is_invertible (matrix))
    10 -	return _cairo_error (CAIRO_STATUS_INVALID_MATRIX);
    11 +    if (! _cairo_matrix_is_invertible (matrix)) {
    12 +	/* rank 0 matrices are ok even though they are not invertible */
    13 +	if (!(matrix->xx == 0. && matrix->xy == 0. &&
    14 +	      matrix->yx == 0. && matrix->yy == 0.)) {
    15 +	    return _cairo_error (CAIRO_STATUS_INVALID_MATRIX);
    16 +	}
    17 +    }
    19      _cairo_gstate_unset_scaled_font (gstate);

mercurial