http://ftp.x.org/contrib/applications/xscreensaver-2.23.tar.gz
[xscreensaver] / driver / timers.c
index bc92893a59c357b0d45503af94e0245f6c42b3a7..89026d1bd6d5b168bba4004cf1966c243e1e1fc2 100644 (file)
@@ -608,6 +608,14 @@ watchdog_timer (XtPointer closure, XtIntervalId *id)
 #endif /* DEBUG_TIMERS */
 
          raise_window (si, True, True, running_p);
+
+         if (!monitor_powered_on_p (si))
+           {
+             if (si->prefs.verbose_p)
+               printf ("%s: server reports that monitor has powered down; "
+                       "killing running hacks.\n", progname);
+             kill_screenhack (si);
+           }
        }
     }
 }