lkml.org 
[lkml]   [2009]   [Dec]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] ACPI: Fix &&/|| confusion in acpi_evaluate_string() (in comment)
This always evaluates to true.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
---
drivers/acpi/utils.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)

It's between an #if 0 ... #endif.

diff --git a/drivers/acpi/utils.c b/drivers/acpi/utils.c
index 811fec1..3495b43 100644
--- a/drivers/acpi/utils.c
+++ b/drivers/acpi/utils.c
@@ -312,7 +312,7 @@ acpi_evaluate_string(acpi_handle handle,
element = (acpi_object *) buffer.pointer;

if ((element->type != ACPI_TYPE_STRING)
- || (element->type != ACPI_TYPE_BUFFER)
+ && (element->type != ACPI_TYPE_BUFFER)
|| !element->string.length) {
acpi_util_eval_error(handle, pathname, AE_BAD_DATA);
return AE_BAD_DATA;

\
 
 \ /
  Last update: 2009-12-31 12:57    [W:0.029 / U:0.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site