doc/go1.11.html | 2 +- doc/go1.13.html | 2 +- doc/go1.14.html | 2 +- doc/go1.9.html | 2 +- src/internal/bytealg/indexbyte_riscv64.s | 8 ++++---- src/net/lookup_test.go | 7 ++----- src/runtime/signal_unix.go | 10 ++++++++++ diff --git a/doc/go1.11.html b/doc/go1.11.html index 841ead225f8f10436a8cc457809d0bcc0ba110c6..483ecd872f354825c454600be7c7805b887f1f40 100644 --- a/doc/go1.11.html +++ b/doc/go1.11.html @@ -826,7 +826,7 @@ -
runtime
+
runtime

diff --git a/doc/go1.13.html b/doc/go1.13.html index a17337f6662c25ae3f51b0bb61da573641b63030..8f4035d87f8460c62f91bd347c4d544fbaf42f3b 100644 --- a/doc/go1.13.html +++ b/doc/go1.13.html @@ -904,7 +904,7 @@

-
runtime
+
runtime

Tracebacks, runtime.Caller, diff --git a/doc/go1.14.html b/doc/go1.14.html index 186899e680e0836cac71a307a775503e8ca1473d..7cf73bc5010dfb61004a475f05f92fc08a5e1325 100644 --- a/doc/go1.14.html +++ b/doc/go1.14.html @@ -736,7 +736,7 @@

-
runtime
+
runtime

runtime.Goexit can no longer be aborted by a diff --git a/doc/go1.9.html b/doc/go1.9.html index 3dfdf53a8113a6830505ae664c303e579ba597ce..86ee257d03b37af852e90bce26ffa175a7a53ae3 100644 --- a/doc/go1.9.html +++ b/doc/go1.9.html @@ -862,7 +862,7 @@

-
runtime
+
runtime

Tracebacks generated by the runtime and recorded in profiles are diff --git a/src/internal/bytealg/indexbyte_riscv64.s b/src/internal/bytealg/indexbyte_riscv64.s index 087be86e44a753925c201bf61cf570e41e7f6544..156c3036997e81015107309a64a47782e06216e1 100644 --- a/src/internal/bytealg/indexbyte_riscv64.s +++ b/src/internal/bytealg/indexbyte_riscv64.s @@ -6,8 +6,8 @@ #include "go_asm.h" #include "textflag.h" TEXT ·IndexByte(SB),NOSPLIT,$0-40 - MOV s+0(FP), A1 - MOV s_len+8(FP), A2 + MOV b_base+0(FP), A1 + MOV b_len+8(FP), A2 MOVBU c+24(FP), A3 // byte to find MOV A1, A4 // store base for later ADD A1, A2 // end @@ -29,8 +29,8 @@ MOV A1, ret+32(FP) RET TEXT ·IndexByteString(SB),NOSPLIT,$0-32 - MOV p+0(FP), A1 - MOV b_len+8(FP), A2 + MOV s_base+0(FP), A1 + MOV s_len+8(FP), A2 MOVBU c+16(FP), A3 // byte to find MOV A1, A4 // store base for later ADD A1, A2 // end diff --git a/src/net/lookup_test.go b/src/net/lookup_test.go index 1663b78ef00d05f07b7ed4fe3663b66f35aacdf3..2bc5592d5ad730c4c5da39a57d1cc63de5b10887 100644 --- a/src/net/lookup_test.go +++ b/src/net/lookup_test.go @@ -1179,12 +1179,9 @@ t.Errorf("Lookup after expiry: Got %v want nil", g) } } -// Issue 31586: don't crash on null byte in name +// Issue 31597: don't panic on null byte in name func TestLookupNullByte(t *testing.T) { testenv.MustHaveExternalNetwork(t) testenv.SkipFlakyNet(t) - _, err := LookupHost("foo\x00bar") // used to crash on Windows - if err == nil { - t.Errorf("unexpected success") - } + LookupHost("foo\x00bar") // check that it doesn't panic; it used to on Windows } diff --git a/src/runtime/signal_unix.go b/src/runtime/signal_unix.go index 3861cace08cecdb4efd825c8ce0e6a0f6ac95b84..d2e669380510cc3ed487f7378f5e1e5545dd4011 100644 --- a/src/runtime/signal_unix.go +++ b/src/runtime/signal_unix.go @@ -412,6 +412,16 @@ if sig == _SIGPROF { sigprofNonGoPC(c.sigpc()) return } + if sig == sigPreempt && preemptMSupported && debug.asyncpreemptoff == 0 { + // This is probably a signal from preemptM sent + // while executing Go code but received while + // executing non-Go code. + // We got past sigfwdgo, so we know that there is + // no non-Go signal handler for sigPreempt. + // The default behavior for sigPreempt is to ignore + // the signal, so badsignal will be a no-op anyway. + return + } c.fixsigcode(sig) badsignal(uintptr(sig), c) return