After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 660962 - Ignore DPMSSetTimeouts() and DPMSForceLevel() return value
Ignore DPMSSetTimeouts() and DPMSForceLevel() return value
Status: RESOLVED FIXED
Product: gnome-desktop
Classification: Core
Component: libgnome-desktop
3.2.x
Other Linux
: Normal normal
: ---
Assigned To: Desktop Maintainers
Desktop Maintainers
Depends on:
Blocks:
 
 
Reported: 2011-10-05 07:48 UTC by Alexandre Rostovtsev
Modified: 2011-10-05 08:16 UTC
See Also:
GNOME target: ---
GNOME version: 3.1/3.2


Attachments
Ignore DPMSSetTimeouts() and DPMSForceLevel() return value (3.02 KB, patch)
2011-10-05 07:51 UTC, Alexandre Rostovtsev
none Details | Review

Description Alexandre Rostovtsev 2011-10-05 07:48:36 UTC
While investigating bug #660859, I added lots of fprintfs to xset-1.2.2 source. And it turned out that, at least under the nvidia binary blob, DPMSSetTimeouts() and DPMSForceLevel() *always* return BadRequest, even when they succeed. On another machine, one with Intel graphics, DPMSSetTimeouts() returns 0 on success (as expected), but DPMSForceLevel() always returns BadRequest.

Basically, I think we should assume that the return values of DPMSSetTimeouts() and DPMSForceLevel() are a terrible, blatant lie, and ignore them.

Incidentally, that is precisely what xset-1.2.2 does.

Fixing this will allow gnome-settings-daemon's power plugin to work correctly.
Comment 1 Alexandre Rostovtsev 2011-10-05 07:51:31 UTC
Created attachment 198308 [details] [review]
Ignore DPMSSetTimeouts() and DPMSForceLevel() return value
Comment 2 Richard Hughes 2011-10-05 08:16:08 UTC
Committed with a small change to remove the duplication (that I introduced with the last patch)

Thanks!