mirror of
https://github.com/VDR4Arch/vdr.git
synced 2023-10-10 13:36:52 +02:00
Fixed handling the 'Power' key in case Setup.MinUserInactivity is set to 0
This commit is contained in:
parent
d78d555b27
commit
62c452561e
2
HISTORY
2
HISTORY
@ -854,3 +854,5 @@ Video Disk Recorder Revision History
|
||||
- Added PTS to the converted PCM audio when replaying a DVD (thanks to Andreas
|
||||
Schultz). Now the audio and video of a DVD replayed over the DVB card's A/V
|
||||
out should always be in sync.
|
||||
- Fixed handling the "Power" key in case Setup.MinUserInactivity is set to 0 to
|
||||
disable automatic shutdown.
|
||||
|
4
vdr.c
4
vdr.c
@ -22,7 +22,7 @@
|
||||
*
|
||||
* The project's page is at http://www.cadsoft.de/people/kls/vdr
|
||||
*
|
||||
* $Id: vdr.c 1.87 2001/10/27 09:47:02 kls Exp $
|
||||
* $Id: vdr.c 1.88 2001/11/03 11:48:21 kls Exp $
|
||||
*/
|
||||
|
||||
#include <getopt.h>
|
||||
@ -483,7 +483,7 @@ int main(int argc, char *argv[])
|
||||
time_t Now = time(NULL);
|
||||
if (Now - LastActivity > ACTIVITYTIMEOUT) {
|
||||
// Shutdown:
|
||||
if (Shutdown && Setup.MinUserInactivity && Now - LastActivity > Setup.MinUserInactivity * 60) {
|
||||
if (Shutdown && (Setup.MinUserInactivity || LastActivity == 1) && Now - LastActivity > Setup.MinUserInactivity * 60) {
|
||||
cTimer *timer = Timers.GetNextActiveTimer();
|
||||
time_t Next = timer ? timer->StartTime() : 0;
|
||||
time_t Delta = timer ? Next - Now : 0;
|
||||
|
Loading…
Reference in New Issue
Block a user