[gnome-desktop] gnome-rr: Don't print an error for no backlight
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-desktop] gnome-rr: Don't print an error for no backlight
- Date: Wed, 14 Sep 2011 00:21:19 +0000 (UTC)
commit 26efa98897aea50fb0d81b7733dd0deeba975e25
Author: Bastien Nocera <hadess hadess net>
Date: Mon Sep 12 17:50:51 2011 +0100
gnome-rr: Don't print an error for no backlight
If there's no support for the backlight property, don't
throw a warning about it.
https://bugzilla.gnome.org/show_bug.cgi?id=658844
libgnome-desktop/gnome-rr.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/libgnome-desktop/gnome-rr.c b/libgnome-desktop/gnome-rr.c
index 8c5e9c9..d5f0590 100644
--- a/libgnome-desktop/gnome-rr.c
+++ b/libgnome-desktop/gnome-rr.c
@@ -1538,10 +1538,11 @@ update_brightness_limits (GnomeRROutput *output)
atom = XInternAtom (DISPLAY (output), "BACKLIGHT", FALSE);
info = XRRQueryOutputProperty (DISPLAY (output), output->id, atom);
rc = gdk_error_trap_pop ();
- if (rc != 0)
+ if (rc != Success)
{
- g_warning ("could not get output property for %s, rc: %i",
- output->name, rc);
+ if (rc != BadName)
+ g_warning ("could not get output property for %s, rc: %i",
+ output->name, rc);
goto out;
}
if (info == NULL)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]