From: Jaroslav Kysela Date: Tue, 10 Feb 2015 17:24:08 +0000 (+0100) Subject: transcode: handle packets with the NULL payload X-Git-Tag: v4.1~362 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=c475b2531beab46ca8f46512cbe329852b7138ba;p=thirdparty%2Ftvheadend.git transcode: handle packets with the NULL payload --- diff --git a/src/plumbing/transcoding.c b/src/plumbing/transcoding.c index f017437ac..4aeafabcd 100644 --- a/src/plumbing/transcoding.c +++ b/src/plumbing/transcoding.c @@ -1252,11 +1252,18 @@ static void transcoder_packet(transcoder_t *t, th_pkt_t *pkt) { transcoder_stream_t *ts; + streaming_message_t *sm; LIST_FOREACH(ts, &t->t_stream_list, ts_link) { if (pkt->pkt_componentindex == ts->ts_index) { - ts->ts_handle_pkt(t, ts, pkt); - return; + if (pkt->pkt_payload) { + ts->ts_handle_pkt(t, ts, pkt); + return; + } else { + sm = streaming_msg_create_pkt(pkt); + streaming_target_deliver2(ts->ts_target, sm); + pkt_ref_dec(pkt); + } } } pkt_ref_dec(pkt);