fix: use golang 1.23 standard library to collect crash logs (#807)

This commit is contained in:
Levi authored and GitHub committed 2024-11-14 00:54:34 +08:00
1 parent aaf73dec24
commit 203385d3f8
12 files changed
+14 -21

No files matched your search

+2 -2
View File
@@ -11,12 +11,12 @@ import (
gonanoid "github.com/matoous/go-nanoid/v2"
"github.com/rs/zerolog"
"github.com/rs/zerolog/pkgerrors"
"github.com/virtuald/go-paniclog"
"math"
gohttp "net/http"
"net/url"
"os"
"path/filepath"
"runtime/debug"
"sort"
"strings"
"sync"
@@ -1130,7 +1130,7 @@ func logPanic(logDir string) {
if err != nil {
return
}
paniclog.RedirectStderr(f)
debug.SetCrashOutput(f, debug.CrashOptions{})
}
func (d *Downloader) buildFetcher(url string) (fetcher.Fetcher, error) {