From: Christian Brauner <christian.brauner@xxxxxxxxxx> We're not using the shortopts anywhere anyway so just rely on longopts. Cc: fstests@xxxxxxxxxxxxxxx Suggested-by: Christoph Hellwig <hch@xxxxxx> Signed-off-by: Christian Brauner <christian.brauner@xxxxxxxxxx> --- /* v2 */ patch not present /* v3 */ - Christoph Hellwig <hch@xxxxxx>: - Split into separate patch. --- src/idmapped-mounts/idmapped-mounts.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/idmapped-mounts/idmapped-mounts.c b/src/idmapped-mounts/idmapped-mounts.c index 69dcc027..e565246e 100644 --- a/src/idmapped-mounts/idmapped-mounts.c +++ b/src/idmapped-mounts/idmapped-mounts.c @@ -8717,8 +8717,11 @@ static void usage(void) fprintf(stderr, " Run idmapped mount tests\n\n"); fprintf(stderr, "Arguments:\n"); - fprintf(stderr, "-d --device Device used in the tests\n"); - fprintf(stderr, "-m --mountpoint Mountpoint of device\n"); + fprintf(stderr, "--device Device used in the tests\n"); + fprintf(stderr, "--fstype Filesystem type used in the tests\n"); + fprintf(stderr, "--help Print help\n"); + fprintf(stderr, "--mountpoint Mountpoint of device\n"); + fprintf(stderr, "--supported Test whether idmapped mounts are supported on this filesystem\n"); _exit(EXIT_SUCCESS); } @@ -8826,7 +8829,7 @@ int main(int argc, char *argv[]) int index = 0; bool supported = false; - while ((ret = getopt_long(argc, argv, "", longopts, &index)) != -1) { + while ((ret = getopt_long_only(argc, argv, "d:f:m:sh", longopts, &index)) != -1) { switch (ret) { case 'd': t_device = optarg; -- 2.30.2