Patchwork Go patch committed: Update to current Go library

login
register
mail settings
Submitter Ian Taylor
Date May 24, 2011, 9:07 p.m.
Message ID <mcr7h9fhknq.fsf@coign.corp.google.com>
Download mbox | patch
Permalink /patch/97226/
State New
Headers show

Comments

Ian Taylor - May 24, 2011, 9:07 p.m.
Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> writes:

> On recent Solaris 11, I also have:
>
> const __PATH_SYSVOL = "/system/volatile"
> const __PATH_UTMPX = __PATH_SYSVOL "/utmpx"
> const __PATH_VARRUN = __PATH_SYSVOL "/"
>
> For the moment, I'm just omitting the offending declarations in
> mksysinfo.sh.

This patch should fix this problem.  Bootstrapped and ran Go testsuite
on x86_64-unknown-linux-gnu.  Committed to mainline.

Ian


2011-05-24  Ian Lance Taylor  <iant@google.com>

	* godump.c (go_define): Don't accept a string immediately after
	another operand.

Patch

Index: godump.c
===================================================================
--- godump.c	(revision 174140)
+++ godump.c	(working copy)
@@ -300,7 +300,11 @@  go_define (unsigned int lineno, const ch
 	case '"':
 	case '\'':
 	  {
-	    char quote = *p;
+	    char quote;
+
+	    if (saw_operand)
+	      goto unknown;
+	    quote = *p;
 	    *q++ = *p++;
 	    while (*p != quote)
 	      {