From 41d3d0ac409a6e85a39e453be6ecb99c622284a8 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Thu, 26 Jan 2017 19:07:54 +0000 Subject: [PATCH] runtime: fix setting of isarchive When I updated to Go 1.8, the initsig function moved from signal1_unix.go to signal_unix.go, and lost a gccgo-specific change in the move. Add it back. This would have been caught by the misc/cgo/testcarchive tests in the gc repository, but we don't run those in the gccgo repository. We should fix that, somehow. Reviewed-on: https://go-review.googlesource.com/35839 From-SVN: r244947 --- gcc/go/gofrontend/MERGE | 2 +- libgo/go/runtime/signal_unix.go | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE index 29c971c25a0..7900e1a4aa7 100644 --- a/gcc/go/gofrontend/MERGE +++ b/gcc/go/gofrontend/MERGE @@ -1,4 +1,4 @@ -f8c451ed42fd71b85afab54a33fc321df0ff3b0b +2c62d5223e814887801b1540162c72b90299d910 The first line of this file holds the git revision number of the last merge done from the gofrontend repository. diff --git a/libgo/go/runtime/signal_unix.go b/libgo/go/runtime/signal_unix.go index cd6f3fb9ba1..13b79305fda 100644 --- a/libgo/go/runtime/signal_unix.go +++ b/libgo/go/runtime/signal_unix.go @@ -66,6 +66,11 @@ var signalsOK bool //go:nosplit //go:nowritebarrierrec func initsig(preinit bool) { + if preinit { + // preinit is only passed as true if isarchive should be true. + isarchive = true + } + if !preinit { // It's now OK for signal handlers to run. signalsOK = true -- 2.30.2