From d12ddbec488a7b3ca5f79dcc8de17de18b82882f Mon Sep 17 00:00:00 2001 From: John Mark Bell Date: Mon, 5 Apr 2010 22:09:11 +0000 Subject: Fix RISC OS build svn path=/trunk/libcss/; revision=10247 --- src/select/properties.c | 3 ++- src/stylesheet.c | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/select/properties.c b/src/select/properties.c index 5342964..4338cb8 100644 --- a/src/select/properties.c +++ b/src/select/properties.c @@ -69,7 +69,8 @@ static uint32_t generic_destroy_uri(void *bytecode) bool has_uri = (getValue(*((uint32_t*)bytecode)) & BACKGROUND_IMAGE_URI) == BACKGROUND_IMAGE_URI; if (has_uri) { - lwc_string *str = *(lwc_string **)(((uint8_t*)bytecode) + sizeof(uint32_t)); + void *vstr = (((uint8_t*)bytecode) + sizeof(uint32_t)); + lwc_string *str = *(lwc_string **) vstr; lwc_string_unref(str); } return sizeof(uint32_t) + (has_uri ? sizeof(lwc_string*) : 0); diff --git a/src/stylesheet.c b/src/stylesheet.c index b10686f..52f2eed 100644 --- a/src/stylesheet.c +++ b/src/stylesheet.c @@ -586,18 +586,18 @@ css_error css_stylesheet_style_destroy(css_stylesheet *sheet, css_style *style, bool suppress_bytecode_cleanup) { uint32_t alloclen, bucket; - uint8_t *bptr, *eptr; + void *bptr, *eptr; if (sheet == NULL || style == NULL) return CSS_BADPARM; if (suppress_bytecode_cleanup == false) { bptr = style->bytecode; - eptr = bptr + style->length; + eptr = (uint8_t *) bptr + style->length; while (bptr != eptr) { uint32_t opcode = getOpcode(*((uint32_t*)bptr)); uint32_t skip = prop_dispatch[opcode].destroy(bptr); - bptr += skip; + bptr = (uint8_t *) bptr + skip; } } -- cgit v1.2.3