Fix panic when using default-initialized FlagSet
Closes #13294 Signed-off-by: Sebastien Rannou <mxs@sbrk.org>
This commit is contained in:
parent
bca14f8730
commit
08683e7133
1 changed files with 1 additions and 1 deletions
|
@ -560,7 +560,7 @@ func defaultUsage(f *FlagSet) {
|
|||
// Usage prints to standard error a usage message documenting all defined command-line flags.
|
||||
// The function is a variable that may be changed to point to a custom function.
|
||||
var Usage = func() {
|
||||
fmt.Fprintf(CommandLine.output, "Usage of %s:\n", os.Args[0])
|
||||
fmt.Fprintf(CommandLine.Out(), "Usage of %s:\n", os.Args[0])
|
||||
PrintDefaults()
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue