Skip to content
This repository was archived by the owner on May 6, 2020. It is now read-only.

Commit 197707f

Browse files
author
Graham Whaley
authored
Merge pull request #142 from jodh-intel/coredump-on-error
init: coredump on internal error
2 parents f59425f + e9ba5cb commit 197707f

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

proxy.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ import (
2626
"net/url"
2727
"os"
2828
"path/filepath"
29+
"runtime/debug"
2930
"strconv"
3031
"strings"
3132
"sync"
@@ -618,6 +619,9 @@ func (proxy *proxy) init() error {
618619
var l net.Listener
619620
var err error
620621

622+
// Force a coredump + full stacktrace on internal error
623+
debug.SetTraceback("crash")
624+
621625
// flags
622626
proxy.enableVMConsole = logrus.GetLevel() == logrus.DebugLevel
623627

0 commit comments

Comments
 (0)