()
| 125 | } |
| 126 | |
| 127 | func rerunWithFastCrash() { |
| 128 | if os.Getenv("GORACE") != "log_path=stderr halt_on_error=1" { |
| 129 | _ = os.Setenv("GORACE", "log_path=stderr halt_on_error=1") |
| 130 | /* #nosec G204 */ |
| 131 | c := exec.Command(os.Args[0], os.Args[1:]...) |
| 132 | c.Stderr = os.Stderr |
| 133 | if err, ok := c.Run().(*exec.ExitError); ok { |
| 134 | if status, ok := err.Sys().(syscall.WaitStatus); ok { |
| 135 | os.Exit(status.ExitStatus()) |
| 136 | } |
| 137 | os.Exit(1) |
| 138 | } |
| 139 | os.Exit(0) |
| 140 | } |
| 141 | } |
| 142 | |
| 143 | // panicDoRaceWrite and panicDoRaceRead are extracted from panicRace() to make |
| 144 | // the stack trace less trivial, but in general folks will do the error with |
no outgoing calls
no test coverage detected
searching dependent graphs…