tree-wide: convert open calls to remove spaces to skip_spaces() lib function
[safe/jmp/linux-2.6] / drivers / platform / x86 / thinkpad_acpi.c
index 0ed8480..cf61d6a 100644 (file)
@@ -1006,11 +1006,8 @@ static int parse_strtoul(const char *buf,
 {
        char *endp;
 
-       while (*buf && isspace(*buf))
-               buf++;
-       *value = simple_strtoul(buf, &endp, 0);
-       while (*endp && isspace(*endp))
-               endp++;
+       *value = simple_strtoul(skip_spaces(buf), &endp, 0);
+       endp = skip_spaces(endp);
        if (*endp || *value > max)
                return -EINVAL;