Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
DVR: dvr_entry_get_epg_running should return zero if de_dvb_eid is no…
…t set
  • Loading branch information
perexg committed Nov 16, 2015
1 parent 223cd0a commit 197f454
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/dvr/dvr_db.c
Expand Up @@ -282,6 +282,8 @@ dvr_entry_get_rerecord_errors( dvr_entry_t *de )
int
dvr_entry_get_epg_running( dvr_entry_t *de )
{
if (de->de_dvb_eid == 0)
return 0;
if (de->de_channel->ch_epg_running < 0)
return de->de_config->dvr_running;
return de->de_channel->ch_epg_running > 0;
Expand Down Expand Up @@ -1621,7 +1623,7 @@ void dvr_event_running(epg_broadcast_t *e, epg_source_t esrc, int running)
if (esrc != EPG_SOURCE_EIT || e->dvb_eid == 0 || e->channel == NULL)
return;
LIST_FOREACH(de, &e->channel->ch_dvrs, de_channel_link) {
if (de->de_dvb_eid == 0 || !dvr_entry_get_epg_running(de)) {
if (!dvr_entry_get_epg_running(de)) {
atomic_exchange_time_t(&de->de_running_start, 0);
atomic_exchange_time_t(&de->de_running_stop, 0);
continue;
Expand Down

0 comments on commit 197f454

Please sign in to comment.