mirror of
https://gitlab.freedesktop.org/upower/upower.git
synced 2026-05-09 11:48:02 +02:00
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:
parent
793642bfb7
commit
71e3bb02f9
1 changed files with 1 additions and 1 deletions
|
|
@ -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);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue