UpKbdBacklight: don't check the *end value when using g_ascii_strtoll

g_ascii_strtoll would set end to match buf when a parsing error occurred,
so there's no reason to also check what this is pointing to

https://bugs.freedesktop.org/show_bug.cgi?id=96215
This commit is contained in:
Marco Trevisan (Treviño) 2016-05-25 17:46:37 +02:00 committed by Martin Pitt
parent 793642bfb7
commit 71e3bb02f9

View file

@ -70,7 +70,7 @@ up_kbd_backlight_brightness_read (UpKbdBacklight *kbd_backlight)
if (brightness < 0 ||
brightness > kbd_backlight->priv->max_brightness ||
end == buf || *end != '\0') {
end == buf) {
brightness = -1;
g_warning ("failed to convert brightness: %s", buf);
}