Submitted By: Uwe Düffert (lfs at uwe-dueffert dot de)
Date: 2006-01-06
Initial Package Version: 2.16.91.0.5
Origin: self-created, http://www.uwe-dueffert.de/lfs/ownpatches/binutils-2.16.91.0.5-gcc4-1.patch
Upstream Status: not reported
Description: fix compilation with gcc4.x
diff -Naur binutils-2.16.91.0.5.orig/bfd/ecoff.c binutils-2.16.91.0.5/bfd/ecoff.c
--- binutils-2.16.91.0.5.orig/bfd/ecoff.c	2005-07-20 21:27:27.000000000 +0200
+++ binutils-2.16.91.0.5/bfd/ecoff.c	2006-01-06 00:08:37.000000000 +0100
@@ -3087,7 +3087,7 @@
   last_elt = current;
   for (i = 0; i < orl_count; i++)
     {
-      unsigned int hash, rehash;
+      unsigned int hash, rehash=0;
 
       /* Advance firstreal to the file position of this archive
 	 element.  */
@@ -3756,7 +3756,7 @@
   while (*pundef != NULL)
     {
       struct bfd_link_hash_entry *h;
-      unsigned int hash, rehash;
+      unsigned int hash, rehash=0;
       unsigned int file_offset;
       const char *name;
       bfd *element;
diff -Naur binutils-2.16.91.0.5.orig/binutils/wrstabs.c binutils-2.16.91.0.5/binutils/wrstabs.c
--- binutils-2.16.91.0.5.orig/binutils/wrstabs.c	2005-05-11 00:46:43.000000000 +0200
+++ binutils-2.16.91.0.5/binutils/wrstabs.c	2006-01-06 00:08:40.000000000 +0100
@@ -1867,7 +1867,7 @@
 {
   struct stab_write_handle *info = (struct stab_write_handle *) p;
   long index;
-  unsigned int size;
+  unsigned int size=0;
 
   index = stab_get_struct_index (info, name, id, kind, &size);
   if (index < 0)
diff -Naur binutils-2.16.91.0.5.orig/gas/read.c binutils-2.16.91.0.5/gas/read.c
--- binutils-2.16.91.0.5.orig/gas/read.c	2005-12-20 23:43:55.000000000 +0100
+++ binutils-2.16.91.0.5/gas/read.c	2006-01-06 00:08:39.000000000 +0100
@@ -1279,7 +1279,7 @@
   unsigned int align_limit = ALIGN_LIMIT;
   unsigned int align;
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
   offsetT fill = 0;
   int max;
   int fill_p;
@@ -1423,7 +1423,7 @@
   offsetT temp, size;
   symbolS *symbolP = NULL;
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
   expressionS exp;
 
   if (flag_mri)
@@ -1538,7 +1538,7 @@
   symbolS *sym;
   offsetT align;
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
 
   if (!flag_mri)
     {
@@ -1807,7 +1807,7 @@
 {
   offsetT temp;
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
 
   if (flag_mri)
     stop = mri_comment_field (&stopc);
@@ -1929,7 +1929,7 @@
   int c;
   symbolS *symbolP;
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
 
   if (flag_mri)
     stop = mri_comment_field (&stopc);
@@ -2881,7 +2881,7 @@
   expressionS val;
   char *p = 0;
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
   int bytes;
 
 #ifdef md_flush_pending_output
@@ -3057,7 +3057,7 @@
   int flen;
   char temp[MAXIMUM_NUMBER_OF_CHARS_FOR_FLOAT];
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
 
   if (flag_mri)
     stop = mri_comment_field (&stopc);
@@ -3134,7 +3134,7 @@
 s_struct (int ignore ATTRIBUTE_UNUSED)
 {
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
 
   if (flag_mri)
     stop = mri_comment_field (&stopc);
@@ -3514,7 +3514,7 @@
   int c;
   expressionS exp;
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
 
 #ifdef md_flush_pending_output
   md_flush_pending_output ();
@@ -5010,7 +5010,7 @@
 equals (char *sym_name, int reassign)
 {
   char *stop = NULL;
-  char stopc;
+  char stopc=0;
 
   input_line_pointer++;
   if (*input_line_pointer == '=')
