Project

General

Profile

Bug #4640 » 4640-only-dup-same-start-time-with-debug.patch

Em Smith, 2017-10-04 01:07

View differences:

src/dvr/dvr_db.c
1528 1528
  /* Identical duplicate detection
1529 1529
     NOTE: Semantic duplicate detection is deferred to the start time of recording and then done using _dvr_duplicate_event by dvr_timer_start_recording. */
1530 1530
  LIST_FOREACH(de, &dvrentries, de_global_link) {
1531
    if (de->de_bcast == e || (de->de_bcast && de->de_bcast->episode == e->episode))
1532
      if (strcmp(dae->dae_owner ?: "", de->de_owner ?: "") == 0)
1533
        return;
1531
    if ((de->de_bcast == e || (de->de_bcast && de->de_bcast->episode == e->episode)) && e->start == de->de_start)
1532
      if (strcmp(dae->dae_owner ?: "", de->de_owner ?: "") == 0) {
1533
        char estartbuf[64], destartbuf[64];
1534
        tvhinfo(LS_DVR, "Autorecord \"%s\": Not scheduling \"%s\" on channel \"%s\" because dup on \"%s\" start: %"PRId64 " and de start: %"PRId64 " (e: %s de: %s)",
1535
            dae->dae_name?:"", lang_str_get(e->episode->title, NULL), channel_get_name(e->channel, channel_blank_name), channel_get_name(de->de_channel, channel_blank_name), (int64_t)e->start, (int64_t)de->de_start, gmtime2local(e->start, estartbuf, sizeof estartbuf), gmtime2local(de->de_start, destartbuf, sizeof destartbuf));
1536
         return;
1537
      }
1534 1538
  }
1535 1539

  
1536 1540
  /* Handle max schedules limit for autorrecord */
(5-5/5)