mirror of
https://github.com/octoleo/syncthing.git
synced 2025-01-09 17:53:59 +00:00
cmd/syncthing: Restore useful levels of traceback on panic
This commit is contained in:
parent
467c1b26fb
commit
d5a0f91cb4
@ -23,6 +23,7 @@ import (
|
|||||||
"path/filepath"
|
"path/filepath"
|
||||||
"regexp"
|
"regexp"
|
||||||
"runtime"
|
"runtime"
|
||||||
|
"runtime/debug"
|
||||||
"runtime/pprof"
|
"runtime/pprof"
|
||||||
"sort"
|
"sort"
|
||||||
"strconv"
|
"strconv"
|
||||||
@ -280,6 +281,9 @@ func parseCommandLineOptions() RuntimeOptions {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
// We want all (our) goroutines in panic traces.
|
||||||
|
debug.SetTraceback("all")
|
||||||
|
|
||||||
options := parseCommandLineOptions()
|
options := parseCommandLineOptions()
|
||||||
l.SetFlags(options.logFlags)
|
l.SetFlags(options.logFlags)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user