summaryrefslogtreecommitdiff
path: root/binutils/sysinfo.y
diff options
context:
space:
mode:
authorAlan Modra <amodra@bigpond.net.au>2005-02-22 12:57:27 +0000
committerAlan Modra <amodra@bigpond.net.au>2005-02-22 12:57:27 +0000
commit0fa07a9d775852c070113ccb1f27da3e14ae3cf5 (patch)
tree1176e8e57a22ed19a81abc9ce4896b1a1f3c2ab6 /binutils/sysinfo.y
parente9a32c3d0ccc2ceee814eca1c5ee07c4c1289fe5 (diff)
downloadbinutils-redhat-0fa07a9d775852c070113ccb1f27da3e14ae3cf5.tar.gz
* Makefile.am (syslex.o, sysinfo.o): Pass AM_CFLAGS to compiler.
(syslex.o, sysinfo.o, dlltool.o, rescoff.o): Remove duplicate dependencies. Run "make dep-am". * nlmconv.c: Warning fixes. * readelf.c: Likewise. * srconv.c: Likewise. * sysdump.c: Likewise. * sysinfo.y: Likewise. * syslex.l: Likewise. Use yyleng instead of strlen, memcpy instead of strcpy. * Makefile.in: Regenerate.
Diffstat (limited to 'binutils/sysinfo.y')
-rw-r--r--binutils/sysinfo.y11
1 files changed, 7 insertions, 4 deletions
diff --git a/binutils/sysinfo.y b/binutils/sysinfo.y
index bf19263c5d..807ac7876e 100644
--- a/binutils/sysinfo.y
+++ b/binutils/sysinfo.y
@@ -1,4 +1,4 @@
-/* Copyright 2001, 2003 Free Software Foundation, Inc.
+/* Copyright 2001, 2003, 2005 Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support (steve@cygnus.com).
This file is part of GNU binutils.
@@ -37,6 +37,9 @@ int rdepth;
char *loop [] = {"","n","m","/*BAD*/"};
char *names[] = {" ","[n]","[n][m]"};
char *pnames[]= {"","*","**"};
+
+static int yyerror (char *s);
+extern int yylex (void);
%}
@@ -117,7 +120,7 @@ it:
printf("void sysroff_swap_%s_in(ptr)\n",$2);
printf("struct IT_%s *ptr;\n", it);
printf("{\n");
- printf("char raw[255];\n");
+ printf("unsigned char raw[255];\n");
printf("\tint idx = 0 ;\n");
printf("\tint size;\n");
printf("memset(raw,0,255);\n");
@@ -129,7 +132,7 @@ it:
printf("FILE * file;\n");
printf("struct IT_%s *ptr;\n", it);
printf("{\n");
- printf("\tchar raw[255];\n");
+ printf("\tunsigned char raw[255];\n");
printf("\tint idx = 16 ;\n");
printf("\tmemset (raw, 0, 255);\n");
printf("\tcode = IT_%s_CODE;\n", it);
@@ -431,7 +434,7 @@ if (writecode == 'd')
return 0;
}
-int
+static int
yyerror (char *s)
{
fprintf(stderr, "%s\n" , s);