diff options
author | kaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk> | 2005-08-08 08:32:52 +0000 |
---|---|---|
committer | kaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk> | 2005-08-08 08:32:52 +0000 |
commit | 5175be99420813b64bbe6687d8225ccf25374375 (patch) | |
tree | 46e722f9cb88c5f879a0ddc1efeff1733edb8779 /xen/tools | |
parent | aba8322b543c753ed1806098085aa20379bebabd (diff) | |
download | xen-5175be99420813b64bbe6687d8225ccf25374375.tar.gz xen-5175be99420813b64bbe6687d8225ccf25374375.tar.bz2 xen-5175be99420813b64bbe6687d8225ccf25374375.zip |
The attached patch adds -Werror to HOSTCFLAGS in Config.mk, makes
xen/tools actually use HOSTCFLAGS (it was already using HOSTCC), and
fixes some gcc-4.0 signedness warnings in xen/tools/symbols.c.
Signed-off-by: Josh Triplett <josht@us.ibm.com>
Diffstat (limited to 'xen/tools')
-rw-r--r-- | xen/tools/Makefile | 2 | ||||
-rw-r--r-- | xen/tools/symbols.c | 10 |
2 files changed, 6 insertions, 6 deletions
diff --git a/xen/tools/Makefile b/xen/tools/Makefile index 04d7020cd8..4d353617bd 100644 --- a/xen/tools/Makefile +++ b/xen/tools/Makefile @@ -10,4 +10,4 @@ clean: rm -f *.o symbols symbols: symbols.c - $(HOSTCC) -o $@ $< + $(HOSTCC) $(HOSTCFLAGS) -o $@ $< diff --git a/xen/tools/symbols.c b/xen/tools/symbols.c index a5665cc124..7bc141e210 100644 --- a/xen/tools/symbols.c +++ b/xen/tools/symbols.c @@ -152,8 +152,8 @@ read_symbol(FILE *in, struct sym_entry *s) /* include the type field in the symbol name, so that it gets * compressed together */ s->len = strlen(str) + 1; - s->sym = (char *) malloc(s->len + 1); - strcpy(s->sym + 1, str); + s->sym = (unsigned char *) malloc(s->len + 1); + strcpy((char *)s->sym + 1, str); s->sym[0] = s->type; return 0; @@ -197,16 +197,16 @@ symbol_valid(struct sym_entry *s) * move then they may get dropped in pass 2, which breaks the * symbols rules. */ - if (s->addr == _etext && strcmp(s->sym + offset, "_etext")) + if (s->addr == _etext && strcmp((char *)s->sym + offset, "_etext")) return 0; } /* Exclude symbols which vary between passes. */ - if (strstr(s->sym + offset, "_compiled.")) + if (strstr((char *)s->sym + offset, "_compiled.")) return 0; for (i = 0; special_symbols[i]; i++) - if( strcmp(s->sym + offset, special_symbols[i]) == 0 ) + if( strcmp((char *)s->sym + offset, special_symbols[i]) == 0 ) return 0; return 1; |