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]

[PATCH] don't mix signed and unsigned


I want to apply this for mainline and 2.13 to make GCC happy:

/usr/src/contrib/binutils/bfd/elf-eh-frame.c: In function `_bfd_elf_discard_section_eh_frame':
/usr/src/contrib/binutils/bfd/elf-eh-frame.c:417: warning: comparison between signed and unsigned


2002-10-11  David O'Brien  <obrien@FreeBSD.org>

	* elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't mix
	signed and unsigned in comparison.

Index: elf-eh-frame.c
===================================================================
RCS file: /cvs/src/src/bfd/elf-eh-frame.c,v
retrieving revision 1.11.4.1
diff -u -r1.11.4.1 elf-eh-frame.c
--- elf-eh-frame.c	23 Sep 2002 22:12:39 -0000	1.11.4.1
+++ elf-eh-frame.c	12 Oct 2002 04:16:06 -0000
@@ -414,7 +414,7 @@
 	    /* 64-bit .eh_frame is not supported.  */
 	    goto free_no_table;
 	  buf += 4;
-	  if ((buf - ehbuf) + hdr.length > sec->_raw_size)
+	  if ((bfd_size_type) (buf - ehbuf) + hdr.length > sec->_raw_size)
 	    /* CIE/FDE not contained fully in this .eh_frame input section.  */
 	    goto free_no_table;



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