Skip to content

Commit

Permalink
don't treat "channel" as required in dvrEntryAdd messages, fixes #74
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam Stenvall committed Sep 21, 2015
1 parent c3e6231 commit 1c14039
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
1 change: 1 addition & 0 deletions pvr.hts/changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
- added: include satpos in mux description
- improved: Do not try to reconnect to tvh while suspending or not fully awake again.
- simplified recording playback handling, fixes random skipping to the beginning of recordings
- fixed: recordings from channels that have been deleted since were not available in Kodi

2.1.17
- fixed: provide a transitional package to fix upgrade path
Expand Down
13 changes: 6 additions & 7 deletions src/Tvheadend.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1374,12 +1374,6 @@ void CTvheadend::ParseRecordingAddOrUpdate ( htsmsg_t *msg, bool bAdd )
return;
}

if (htsmsg_get_u32(msg, "channel", &channel) && bAdd)
{
tvherror("malformed dvrEntryAdd: 'channel' missing");
return;
}

if (htsmsg_get_s64(msg, "start", &start) && bAdd)
{
tvherror("malformed dvrEntryAdd: 'start' missing");
Expand All @@ -1402,10 +1396,15 @@ void CTvheadend::ParseRecordingAddOrUpdate ( htsmsg_t *msg, bool bAdd )
SRecording &rec = m_recordings[id];
rec.id = id;
rec.del = false;
UPDATE(rec.channel, channel);
UPDATE(rec.start, start);
UPDATE(rec.stop, stop);

/* Channel is optional, it may not exist anymore */
if (!htsmsg_get_u32(msg, "channel", &channel))
{
UPDATE(rec.channel, channel);
}

if (!htsmsg_get_s64(msg, "startExtra", &startExtra))
{
UPDATE(rec.startExtra, startExtra);
Expand Down

0 comments on commit 1c14039

Please sign in to comment.