internal/crashmonitor: prepare for SetCrashOutput signature change
The function is about to get a second parameter.
This shim will be removed later this week.
Updates golang/go#67182
Change-Id: I166adda831979b713d429504b57510506bfdff11
Reviewed-on: https://go-review.googlesource.com/c/telemetry/+/585378
Reviewed-by: Michael Matloob <matloob@golang.org>
Auto-Submit: Alan Donovan <adonovan@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
diff --git a/internal/crashmonitor/crash_go123.go b/internal/crashmonitor/crash_go123.go
index 2e0c1b3..a2706d3 100644
--- a/internal/crashmonitor/crash_go123.go
+++ b/internal/crashmonitor/crash_go123.go
@@ -7,8 +7,11 @@
package crashmonitor
-import "runtime/debug"
+import (
+ "os"
+ "runtime/debug"
+)
func init() {
- setCrashOutput = debug.SetCrashOutput
+ setCrashOutput = func(f *os.File) error { return debug.SetCrashOutput(f) }
}