GNOME Bugzilla – Bug 577749
Confusing warning: "Unable to find watch for alarm XXXXX"
Last modified: 2009-04-08 15:31:25 UTC
Please describe the problem: gnome-session seems to report the above warning at random times during desktop session. This can be confusing to a user when noticed in either syslog or console output. The problem is that alarms that are being created to check on session's idle state, are later destroyed when conditions for it are satisfied. However, when an alarm is destroyed, xserver will send an event on it, and gnome-session will try to locate the appropriate watch for that alarm which can't be located. Most correct implementation would keep the watch structure and release it on receipt of the final alarm event, but short of that, switching the message log level from warning to debug removes the confusion. Steps to reproduce: Actual results: Expected results: Does this happen every time? Other information:
Created attachment 131929 [details] [review] Proposed patch to disable no watch warning.
Created attachment 131966 [details] [review] Much improved patch proposal that disables useless warning only when it is really useless. After spending some time on XSync protocol description, I realized that the server does send an event with the state Destroyed after destroying an alarm. This patch ignores such events. As long as alarms are only destroyed from watch remove callback, this should work perfectly. However if that changes, the whole event handler will need to change anyway.
Matthias actually committed a patch similar to your second one a few days ago :-)
Yup, he got it from me from the fedora bugzilla.