Print an error when a user does not supply a NID argument to the
'lnetctl discover' command.
Test-Parameters: trivial
HPE-bug-id: LUS-11487
Signed-off-by: Chris Horn <chris.horn@hpe.com>
Change-Id: I081137db5490547a69248b7d2e7f7986b6d8612e
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/51790
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Serguei Smirnov <ssmirnov@whamcloud.com>
Reviewed-by: Cyril Bordage <cbordage@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
}
}
+ if (optind == argc) {
+ printf("Missing nid argument\n");
+ return -1;
+ }
+
for (; optind < argc; optind++)
rc = lustre_lnet_discover_nid(argv[optind], force, -1, &show_rc,
&err_rc);