From ef994fc9d5bce83f1fb0eb7694d738932f60e37d Mon Sep 17 00:00:00 2001 From: Alex Zhuravlev Date: Sun, 17 Jun 2012 10:18:15 +0400 Subject: [PATCH] LU-1581 utils: unknown fstype scream and exit if specific fstype is not recognized Signed-off-by: Alex Zhuravlev Change-Id: Ib5e897bdfe9609be81d74a41fd65ec57b6cf5d37 --- lustre/utils/mkfs_lustre.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lustre/utils/mkfs_lustre.c b/lustre/utils/mkfs_lustre.c index 21f7d19..0af4fae 100644 --- a/lustre/utils/mkfs_lustre.c +++ b/lustre/utils/mkfs_lustre.c @@ -293,6 +293,11 @@ int parse_opts(int argc, char *const argv[], struct mkfs_opts *mop, } i++; } + if (i == LDD_MT_LAST) { + fprintf(stderr, "%s: invalid backend filesystem" + " type %s\n", progname, optarg); + return 1; + } break; } case 'c': -- 1.8.3.1