Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
DVR: Fix the start conditions and do early stop properly, fixes #3228
  • Loading branch information
perexg committed Oct 30, 2015
1 parent b62e1bd commit 2cab577
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/dvr/dvr_db.c
Expand Up @@ -1585,10 +1585,10 @@ void dvr_event_running(epg_broadcast_t *e, epg_source_t esrc, int running)
epg_broadcast_get_title(e, NULL),
channel_get_name(e->channel));
de->de_running_stop = dispatch_clock;
if (de->de_sched_state == DVR_RECORDING) {
if (de->de_sched_state == DVR_RECORDING && de->de_running_start) {
if (dvr_entry_get_stop_time(de) > dispatch_clock) {
de->de_dont_reschedule = 1;
dvr_entry_set_timer(de);
dvr_stop_recording(de, SM_CODE_OK, 0, 0);
tvhdebug("dvr", "dvr entry %s event %s on %s - EPG stop",
idnode_uuid_as_sstr(&de->de_id),
epg_broadcast_get_title(e, NULL),
Expand Down
2 changes: 2 additions & 0 deletions src/epggrab/module/eit.c
Expand Up @@ -550,6 +550,8 @@ static int _eit_process_event_one
/* use running flag only for current broadcast */
if (running && tableid == 0x4e && sect == 0)
epg_broadcast_notify_running(ebc, EPG_SOURCE_EIT, running == 4);
if (running && running != 4 && tableid == 0x4e && sect == 1)
epg_broadcast_notify_running(ebc, EPG_SOURCE_EIT, 0);

return 0;
}
Expand Down

0 comments on commit 2cab577

Please sign in to comment.