If the -h flag is specified, currently it makes Errorf panic, but
not Exitf. Do so for Exitf as well.
Change-Id: I3e8d8899fd439f7299be3f9e9a63993b04852a93
Reviewed-on: https://go-review.googlesource.com/c/go/+/470297
Run-TryBot: Cherry Mui <cherryyz@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Than McIntosh <thanm@google.com>
func Exitf(format string, a ...interface{}) {
fmt.Fprintf(os.Stderr, os.Args[0]+": "+format+"\n", a...)
nerrors++
+ if *flagH {
+ panic("error")
+ }
Exit(2)
}