summaryrefslogtreecommitdiff
path: root/src/cairo-gstate.c
diff options
context:
space:
mode:
authorAdrian Johnson <ajohnson@redneon.com>2023-02-08 20:09:15 +1030
committerAdrian Johnson <ajohnson@redneon.com>2023-02-08 20:09:15 +1030
commite85c242f0a4306f829b9587233dd366f2443a620 (patch)
treeee5ebacd6add423a3538056b60efadae32e8ca29 /src/cairo-gstate.c
parent4fbc2ea3869a5148529ee59161d78952b64bb697 (diff)
downloadcairo-e85c242f0a4306f829b9587233dd366f2443a620.tar.gz
Implement a font options compare function and use it in gstate
Valgrind is not happy with the memcmp() to compare font options and it won't work correctly with variations and custom_palette.
Diffstat (limited to 'src/cairo-gstate.c')
-rw-r--r--src/cairo-gstate.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cairo-gstate.c b/src/cairo-gstate.c
index 0f4fd541a..8a253468d 100644
--- a/src/cairo-gstate.c
+++ b/src/cairo-gstate.c
@@ -1748,7 +1748,7 @@ void
_cairo_gstate_set_font_options (cairo_gstate_t *gstate,
const cairo_font_options_t *options)
{
- if (memcmp (options, &gstate->font_options, sizeof (cairo_font_options_t)) == 0)
+ if (_cairo_font_options_compare (options, &gstate->font_options))
return;
_cairo_gstate_unset_scaled_font (gstate);