X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;ds=sidebyside;f=lustre%2Futils%2Flustre_lfsck.c;h=b09742bbe88f88ef360905cc9795a9abaa3d3f28;hb=4bf65a2f6b215644b17ed20beaae1b7ff1a73bc5;hp=94f0b2b12ffe035d6f390ff168885ab50c4b6302;hpb=13c8d5e4bebf437227d95582c36ec1567b150cac;p=fs%2Flustre-release.git diff --git a/lustre/utils/lustre_lfsck.c b/lustre/utils/lustre_lfsck.c index 94f0b2b..b09742b 100644 --- a/lustre/utils/lustre_lfsck.c +++ b/lustre/utils/lustre_lfsck.c @@ -71,19 +71,17 @@ static struct option long_opt_start[] = { }; static struct option long_opt_stop[] = { - {"device", required_argument, 0, 'M'}, - {"all", no_argument, 0, 'A'}, - {"help", no_argument, 0, 'h'}, - {0, 0, 0, 0 } -}; + { .val = 'A', .name = "all", .has_arg = no_argument }, + { .val = 'h', .name = "help", .has_arg = no_argument }, + { .val = 'M', .name = "device", .has_arg = required_argument }, + { .name = NULL } }; static struct option long_opt_query[] = { - {"device", required_argument, 0, 'M'}, - {"type", required_argument, 0, 't'}, - {"help", no_argument, 0, 'h'}, - {"wait", no_argument, 0, 'w'}, - {0, 0, 0, 0 } -}; + { .val = 'h', .name = "help", .has_arg = no_argument }, + { .val = 'M', .name = "device", .has_arg = required_argument }, + { .val = 't', .name = "type", .has_arg = required_argument }, + { .val = 'w', .name = "wait", .has_arg = no_argument }, + { .name = NULL } }; struct lfsck_type_name { char *ltn_name;