diff options
author | Cyrill Gorcunov <gorcunov@gmail.com> | 2008-08-20 19:41:45 -0400 |
---|---|---|
committer | Andi Kleen <ak@linux.intel.com> | 2008-08-21 02:45:39 -0400 |
commit | f0df2d6b52ad7db5edf56909509d51be66fe90be (patch) | |
tree | 435643478dd7d18449bccc602abda1fee4e13d98 /drivers/acpi | |
parent | 1371c893ff9de0d57fa5b5cf0255d66b8849e13d (diff) |
acpi: add checking for NULL early param
The early_param handling function could recieve NULL pointer as argument
in case if user didn't enter parameter value. So we have to be ready for
a such situation and do check for NULL pointer if needed.
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Cc: Andi Kleen <andi@firstfloor.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Andi Kleen <ak@linux.intel.com>
Diffstat (limited to 'drivers/acpi')
-rw-r--r-- | drivers/acpi/tables.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/acpi/tables.c b/drivers/acpi/tables.c index c3419182c9a7..775c97a282bd 100644 --- a/drivers/acpi/tables.c +++ b/drivers/acpi/tables.c | |||
@@ -300,6 +300,8 @@ int __init acpi_table_init(void) | |||
300 | 300 | ||
301 | static int __init acpi_parse_apic_instance(char *str) | 301 | static int __init acpi_parse_apic_instance(char *str) |
302 | { | 302 | { |
303 | if (!str) | ||
304 | return -EINVAL; | ||
303 | 305 | ||
304 | acpi_apic_instance = simple_strtoul(str, NULL, 0); | 306 | acpi_apic_instance = simple_strtoul(str, NULL, 0); |
305 | 307 | ||