summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Bursa <james@netsurf-browser.org>2007-05-02 03:17:19 +0000
committerJames Bursa <james@netsurf-browser.org>2007-05-02 03:17:19 +0000
commit828bac39e44538367610939c018988146f07bbd8 (patch)
tree062ebb68d6db3c4ab6fbee6171c1f57365a7627e
parentd0db5ed413a2e956b2774f42f03ca4cc0946f45d (diff)
downloadnetsurf-828bac39e44538367610939c018988146f07bbd8.tar.gz
netsurf-828bac39e44538367610939c018988146f07bbd8.tar.bz2
Fix various warnings.
svn path=/trunk/netsurf/; revision=3263
-rw-r--r--css/css.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/css/css.c b/css/css.c
index ecc2e16ba..c3373f8d9 100644
--- a/css/css.c
+++ b/css/css.c
@@ -395,7 +395,7 @@ bool css_convert(struct content *c, int width, int height)
c->data.css.css = malloc(sizeof *c->data.css.css);
parser = css_parser_Alloc(malloc);
- source_data = talloc_realloc(c, c->source_data, char,
+ source_data = (unsigned char *) talloc_realloc(c, c->source_data, char,
c->source_size + 10);
if (!c->data.css.css || !parser || !source_data) {
@@ -414,7 +414,7 @@ bool css_convert(struct content *c, int width, int height)
c->data.css.import_content = 0;
c->data.css.origin = CSS_ORIGIN_UA;
c->active = 0;
- c->source_data = source_data;
+ c->source_data = (char *) source_data;
for (i = 0; i != 10; i++)
source_data[c->source_size + i] = 0;
@@ -424,13 +424,13 @@ bool css_convert(struct content *c, int width, int height)
while (current < end
&& (token = css_tokenise(&current, end + 10,
&token_text))) {
- token_data.text = token_text;
+ token_data.text = (char *) token_text;
token_data.length = current - token_text;
css_parser_(parser, token, token_data, &param);
if (param.syntax_error) {
- LOG(("syntax error near offset %i (%s)",
- token_text - source_data,
- c->url));
+ LOG(("syntax error near offset %li (%s)",
+ (unsigned long) (token_text - source_data),
+ c->url));
param.syntax_error = false;
} else if (param.memory_error) {
LOG(("out of memory"));
@@ -1524,7 +1524,7 @@ void css_parse_property_list(struct content *c, struct css_style * style,
return;
}
- strcpy(source_data, str);
+ strcpy((char *) source_data, str);
for (i = 0; i != 10; i++)
source_data[length + i] = 0;
@@ -1535,12 +1535,12 @@ void css_parse_property_list(struct content *c, struct css_style * style,
while (current < end
&& (token = css_tokenise(&current, end + 10,
&token_text))) {
- token_data.text = token_text;
+ token_data.text = (char *) token_text;
token_data.length = current - token_text;
css_parser_(parser, token, token_data, &param);
if (param.syntax_error) {
- LOG(("syntax error near offset %i",
- token_text - source_data));
+ LOG(("syntax error near offset %li",
+ (unsigned long) (token_text - source_data)));
param.syntax_error = false;
} else if (param.memory_error) {
LOG(("out of memory"));
@@ -2146,6 +2146,7 @@ void css_dump_style(const struct css_style * const style)
fprintf(stderr, " inherit");
break;
case CSS_BORDER_WIDTH_LENGTH:
+ fprintf(stderr, " ");
css_dump_length(&style->outline.width.value);
break;
case CSS_BORDER_WIDTH_NOT_SET: