This is the mail archive of the binutils@sourceware.org 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: PATCH: PR gas/10704: as segfault in memory lookup intel syntax


On Mon, Oct 05, 2009 at 01:59:08PM +0200, Tristan Gingold wrote:
> So, for the release you propose to revert PR2127 and to add .cfi_sections 
> patch.
> I will do a new pre-release with that.

I have applied the following to mainline, which fixes PR10704 and the
wrong use of expression_and_evaluate I found in s_reloc.  I don't
think this is acceptable for a release, unless you don't care about
ia64.  Jan, do you have any comments on
http://sourceware.org/ml/binutils/2009-10/msg00093.html ?

	PR gas/10704
	* symbols.c (snapshot_symbol): Revert 2006-01-09 patch for PR2117.

	* read.c (s_reloc): Don't use expression_and_evaluate.

Index: gas/symbols.c
===================================================================
RCS file: /cvs/src/src/gas/symbols.c,v
retrieving revision 1.99
diff -u -p -r1.99 symbols.c
--- gas/symbols.c	23 Sep 2009 06:10:08 -0000	1.99
+++ gas/symbols.c	5 Oct 2009 21:45:05 -0000
@@ -1514,10 +1514,7 @@ snapshot_symbol (symbolS **symbolPP, val
 	    }
 	}
 
-      /* Never change a defined symbol.  */
-      if (symbolP->bsym->section == undefined_section
-	  || symbolP->bsym->section == expr_section)
-	*symbolPP = symbolP;
+      *symbolPP = symbolP;
       *valueP = expr.X_add_number;
       *segP = symbolP->bsym->section;
       *fragPP = symbolP->sy_frag;
Index: gas/read.c
===================================================================
RCS file: /cvs/src/src/gas/read.c,v
retrieving revision 1.156
diff -u -p -r1.156 read.c
--- gas/read.c	29 Sep 2009 14:17:07 -0000	1.156
+++ gas/read.c	5 Oct 2009 21:45:08 -0000
@@ -3962,7 +3962,7 @@ s_reloc (int ignore ATTRIBUTE_UNUSED)
   if (*input_line_pointer == ',')
     {
       ++input_line_pointer;
-      expression_and_evaluate (&exp);
+      expression (&exp);
     }
   switch (exp.X_op)
     {

-- 
Alan Modra
Australia Development Lab, IBM


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