Surface usage message for runsc do.

c.Usage() only returns a string; f.Usage() will print the usage message.

PiperOrigin-RevId: 345500123
This commit is contained in:
Dean Deng
2020-12-03 11:47:30 -08:00
committed by gVisor bot
parent 3186b50dff
commit bec8cea651
+1 -1
View File
@@ -81,7 +81,7 @@ func (c *Do) SetFlags(f *flag.FlagSet) {
// Execute implements subcommands.Command.Execute.
func (c *Do) Execute(_ context.Context, f *flag.FlagSet, args ...interface{}) subcommands.ExitStatus {
if len(f.Args()) == 0 {
c.Usage()
f.Usage()
return subcommands.ExitUsageError
}