This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: chew failure on x86_64


On Sat, Jul 23, 2005 at 07:55:05AM -0700, Ian Lance Taylor wrote:
> Daniel Jacobowitz <drow@false.org> writes:
> 
> > > You can't call malloc without a prototype, when pointers are 64 bits
> > > and integers are 32 bits.
> > > 
> > > 2005-07-22  DJ Delorie  <dj@redhat.com>
> > > 
> > > 	* chew.c: Include stdlib.h.
> > 
> > Thanks.  In fact, I didn't realize Kazu's patch left warnings in this
> > file... We're missing prototypes for memcpy, strlen, and strcpy.
> > 
> > Now that we assume ISO C90, can we use <string.h> unconditionally?
> 
> We currently assume a C90 compiler, but we don't assume C90 libraries.
> 
> That said, we do assume in various places that <string.h> exists, so I
> think that is safe.

Yes - for instance gas/input-file.c already uses <string.h>
unconditionally.  I've checked this in.

-- 
Daniel Jacobowitz
CodeSourcery, LLC

2005-07-24  Daniel Jacobowitz  <dan@codesourcery.com>

	* chew.c: Include <string.h>.

Index: bfd/doc/chew.c
===================================================================
RCS file: /cvs/src/src/bfd/doc/chew.c,v
retrieving revision 1.18
diff -u -p -r1.18 chew.c
--- bfd/doc/chew.c	22 Jul 2005 23:54:56 -0000	1.18
+++ bfd/doc/chew.c	24 Jul 2005 16:56:48 -0000
@@ -87,6 +87,7 @@ Foundation, Inc., 51 Franklin Street - F
 #include <stdio.h>
 #include <ctype.h>
 #include <stdlib.h>
+#include <string.h>
 
 #define DEF_SIZE 5000
 #define STACK 50


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]