Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751873AbaFMDEq (ORCPT ); Thu, 12 Jun 2014 23:04:46 -0400 Received: from mail-ie0-f170.google.com ([209.85.223.170]:35993 "EHLO mail-ie0-f170.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751060AbaFMDEp (ORCPT ); Thu, 12 Jun 2014 23:04:45 -0400 From: Nick X-Google-Original-From: Nick To: matthew.garrett@nebula.com Cc: platform-driver-x86@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] platform/x86/toshiba-apci.c possible bad if test? Date: Thu, 12 Jun 2014 23:04:15 -0400 Message-Id: <1402628655-2904-1-git-send-email-nickkrause@sympatico.ca> X-Mailer: git-send-email 1.9.1 Signed-off-by: Nicholas Krause Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org diff --git a/drivers/platform/x86/toshiba_acpi.c b/drivers/platform/x86/toshiba_acpi.c index 76441dc..dfd2243 100644 --- a/drivers/platform/x86/toshiba_acpi.c +++ b/drivers/platform/x86/toshiba_acpi.c @@ -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: -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/