From d5a0f91cb47edffacad759d75eb7ea048b969ec8 Mon Sep 17 00:00:00 2001 From: Jakob Borg Date: Mon, 26 Sep 2016 21:14:17 +0200 Subject: [PATCH] cmd/syncthing: Restore useful levels of traceback on panic --- cmd/syncthing/main.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cmd/syncthing/main.go b/cmd/syncthing/main.go index 4e7bae21..563bafaa 100644 --- a/cmd/syncthing/main.go +++ b/cmd/syncthing/main.go @@ -23,6 +23,7 @@ import ( "path/filepath" "regexp" "runtime" + "runtime/debug" "runtime/pprof" "sort" "strconv" @@ -280,6 +281,9 @@ func parseCommandLineOptions() RuntimeOptions { } func main() { + // We want all (our) goroutines in panic traces. + debug.SetTraceback("all") + options := parseCommandLineOptions() l.SetFlags(options.logFlags)