Commit 8a58a94d authored by Dom Lachowicz's avatar Dom Lachowicz

Fix a "type-punned pointer" issue found by Thomas VS

	* rsvg-paint-server.c: Fix a "type-punned pointer" issue found by Thomas VS
parent d2925c3f
2006-04-29 Dom Lachowicz <cinamod@hotmail.com>
* rsvg-paint-server.c: Fix a "type-punned pointer" issue found by Thomas VS
2006-04-27 Dom Lachowicz <cinamod@hotmail.com>
* rsvg-base.c: Handle system, public, and unparsed entity declarations
......
......@@ -439,8 +439,13 @@ rsvg_pattern_set_atts (RsvgNode * self, RsvgHandle *ctx, RsvgPropertyBag *atts)
pattern->height = _rsvg_css_parse_length (value);
pattern->hasheight = TRUE;
}
if ((value = rsvg_property_bag_lookup (atts, "xlink:href")))
rsvg_defs_add_resolver (ctx->priv->defs, (RsvgNode **)&pattern->fallback, value);
if ((value = rsvg_property_bag_lookup (atts, "xlink:href"))) {
/* The (void *) cast is to avoid a GCC warning like:
* "warning: dereferencing type-punned pointer will break strict-aliasing rules"
* which is wrong for this code. (void *) introduces a compatible
* intermediate type in the cast list. */
rsvg_defs_add_resolver (ctx->priv->defs, (RsvgNode **)(void *)&pattern->fallback, value);
}
if ((value = rsvg_property_bag_lookup (atts, "patternTransform"))){
rsvg_parse_transform (pattern->affine, value);
pattern->hastransform = TRUE;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment