]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
dont crash if there are no more programs in queue
authorAndreas Öman <andreas@lonelycoder.com>
Sat, 8 Sep 2007 04:33:00 +0000 (04:33 +0000)
committerAndreas Öman <andreas@lonelycoder.com>
Sat, 8 Sep 2007 04:33:00 +0000 (04:33 +0000)
epg.c

diff --git a/epg.c b/epg.c
index fd8b2a2daae9b866f075225fee5a7d92d0d85c93..ff2948dfbf1e88b4938eb614950fd25e1b3c86c3 100644 (file)
--- a/epg.c
+++ b/epg.c
@@ -429,7 +429,7 @@ epg_channel_maintain(void)
       continue;
 
     e = TAILQ_NEXT(e, e_link);
-    if(now >= e->e_start && now < e->e_start + e->e_duration) {
+    if(e != NULL && now >= e->e_start && now < e->e_start + e->e_duration) {
       ch->ch_epg_cur_event = e;
       continue;
     }