1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

toolcontext: use proper set of chars to check time format against

This commit is contained in:
Peter Rajnoha 2015-06-29 14:45:45 +02:00
parent 125cd06698
commit 1587236089

View File

@ -443,10 +443,10 @@ static const char *_set_time_format(struct cmd_context *cmd)
chars_to_check = allowed_format_chars;
for (i = 0; chars_to_check[i]; i++) {
if (c == allowed_format_chars[i])
if (c == chars_to_check[i])
break;
}
if (!allowed_format_chars[i])
if (!chars_to_check[i])
goto_bad;
}
else if (isprint(c))