Staging: panel: Reduce value range for *name

out is 0-9 so it's too much for om, therefore reduce value range for
*name from '0'-'9' to '0'-'7'.

Signed-off-by: Ksenija Stanojevic <ksenija.stanojevic@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Ksenija Stanojevic 2016-01-03 20:43:27 +01:00 committed by Greg Kroah-Hartman
parent d12f27e8b2
commit 52ebf93f36
1 changed files with 1 additions and 1 deletions

View File

@ -2065,7 +2065,7 @@ static u8 input_name2mask(const char *name, __u64 *mask, __u64 *value,
im |= BIT(in);
name++;
if (isdigit(*name)) {
if (*name >= '0' && *name <= '7') {
out = *name - '0';
om |= BIT(out);
} else if (*name == '-') {