diff options
author | Tim Wright <tenortim@gmail.com> | 2018-02-13 19:00:17 -0800 |
---|---|---|
committer | Ian Lance Taylor <iant@golang.org> | 2018-03-21 21:56:20 +0000 |
commit | 88129f0cb2438b555fd1dc74c707408251902b4e (patch) | |
tree | 35ac1da60b4186b937b8c78cc5e4747ed5e607eb /src/runtime/signal_unix.go | |
parent | ff5cf43df5b1614f940157b21ca6ed64791b8a1f (diff) | |
download | go-88129f0cb2438b555fd1dc74c707408251902b4e.tar.gz go-88129f0cb2438b555fd1dc74c707408251902b4e.zip |
all: enable c-shared/c-archive support for freebsd/amd64
Fixes #14327
Much of the code is based on the linux/amd64 code that implements these
build modes, and code is shared where possible.
Change-Id: Ia510f2023768c0edbc863aebc585929ec593b332
Reviewed-on: https://go-review.googlesource.com/93875
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/runtime/signal_unix.go')
-rw-r--r-- | src/runtime/signal_unix.go | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/runtime/signal_unix.go b/src/runtime/signal_unix.go index 78649c52a9..d87f1bed16 100644 --- a/src/runtime/signal_unix.go +++ b/src/runtime/signal_unix.go @@ -484,7 +484,10 @@ func raisebadsignal(sig uint32, c *sigctxt) { // re-installing sighandler. At this point we can just // return and the signal will be re-raised and caught by // the default handler with the correct context. - if (isarchive || islibrary) && handler == _SIG_DFL && c.sigcode() != _SI_USER { + // + // On FreeBSD, the libthr sigaction code prevents + // this from working so we fall through to raise. + if GOOS != "freebsd" && (isarchive || islibrary) && handler == _SIG_DFL && c.sigcode() != _SI_USER { return } |