1
0
mirror of git://sourceware.org/git/lvm2.git synced 2025-01-02 01:18:26 +03:00

fix getopt_long error check

This commit is contained in:
Alasdair Kergon 2006-08-10 20:53:21 +00:00
parent 8df67fbf36
commit d2aef510a4

View File

@ -1684,7 +1684,7 @@ static int _process_switches(int *argc, char ***argv)
optind = OPTIND_INIT; optind = OPTIND_INIT;
while ((ind = -1, c = GETOPTLONG_FN(*argc, *argv, "cCfGj:m:Mno:ru:Uv", while ((ind = -1, c = GETOPTLONG_FN(*argc, *argv, "cCfGj:m:Mno:ru:Uv",
long_options, NULL)) != -1) { long_options, NULL)) != -1) {
if (ind == -1 || ind == ':' || ind == '?') if (c == ':' || c == '?')
return 0; return 0;
if (c == 'c' || c == 'C' || ind == COLS_ARG) if (c == 'c' || c == 'C' || ind == COLS_ARG)
_switches[COLS_ARG]++; _switches[COLS_ARG]++;