summaryrefslogtreecommitdiff
path: root/vdr.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2004-10-31 09:37:56 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2004-10-31 09:37:56 +0100
commit3e3f30d88dd33fc1a9859fa59912cd66dd66437d (patch)
tree8789a2f69d4b055207da399fd87b1662f03584ee /vdr.c
parentfc0596d8598a235a1bf9fd3e107213dc1ccc4647 (diff)
downloadvdr-3e3f30d88dd33fc1a9859fa59912cd66dd66437d.tar.gz
vdr-3e3f30d88dd33fc1a9859fa59912cd66dd66437d.tar.bz2
Moved the main program loop variables further up to allow compilation with older compiler versions
Diffstat (limited to 'vdr.c')
-rw-r--r--vdr.c30
1 files changed, 16 insertions, 14 deletions
diff --git a/vdr.c b/vdr.c
index 033f186b..08df727d 100644
--- a/vdr.c
+++ b/vdr.c
@@ -22,7 +22,7 @@
*
* The project's page is at http://www.cadsoft.de/vdr
*
- * $Id: vdr.c 1.190 2004/10/24 14:01:11 kls Exp $
+ * $Id: vdr.c 1.191 2004/10/31 09:35:55 kls Exp $
*/
#include <getopt.h>
@@ -347,6 +347,21 @@ int main(int argc, char *argv[])
isyslog("VDR version %s started", VDRVERSION);
+ // Main program loop variables - need to be here to have them initialized before any EXIT():
+
+ cOsdObject *Menu = NULL;
+ cOsdObject *Temp = NULL;
+ int LastChannel = -1;
+ int LastTimerChannel = -1;
+ int PreviousChannel[2] = { 1, 1 };
+ int PreviousChannelIndex = 0;
+ time_t LastChannelChanged = time(NULL);
+ time_t LastActivity = 0;
+ int MaxLatencyTime = 0;
+ bool ForceShutdown = false;
+ bool UserShutdown = false;
+ bool TimerInVpsMargin = false;
+
// Load plugins:
if (!PluginManager.LoadPlugins(true))
@@ -490,19 +505,6 @@ int main(int argc, char *argv[])
// Main program loop:
- static cOsdObject *Menu = NULL;
- static cOsdObject *Temp = NULL;
- static int LastChannel = -1;
- static int LastTimerChannel = -1;
- static int PreviousChannel[2] = { 1, 1 };
- static int PreviousChannelIndex = 0;
- static time_t LastChannelChanged = time(NULL);
- static time_t LastActivity = 0;
- static int MaxLatencyTime = 0;
- static bool ForceShutdown = false;
- static bool UserShutdown = false;
- static bool TimerInVpsMargin = false;
-
while (!Interrupted) {
// Handle emergency exits:
if (cThread::EmergencyExit()) {