]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
platform/x86/toshiba-apci.c possible bad if test?
authorNick <xerofoify@gmail.com>
Fri, 13 Jun 2014 03:04:15 +0000 (23:04 -0400)
committerMatthew Garrett <matthew.garrett@nebula.com>
Sat, 16 Aug 2014 08:23:49 +0000 (01:23 -0700)
Signed-off-by: Matthew Garrett <matthew.garrett@nebula.com>
drivers/platform/x86/toshiba_acpi.c

index 76441dcbe5ffcd83abbecbedbfd91852b5301c67..dfd2243451ba4f8e27f2371d42a9e5cb1d50e94d 100644 (file)
@@ -1238,7 +1238,7 @@ static ssize_t toshiba_kbd_bl_mode_store(struct device *dev,
        int mode = -1;
        int time = -1;
 
-       if (sscanf(buf, "%i", &mode) != 1 && (mode != 2 || mode != 1))
+       if (sscanf(buf, "%i", &mode) != 1  || (mode != 2 || mode != 1))
                return -EINVAL;
 
        /* Set the Keyboard Backlight Mode where: