Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add rtcp info to the rtsp_priv struct init and free rtcp info from rt…
…sp start and stop
  • Loading branch information
adrienclerc authored and perexg committed Jun 2, 2015
1 parent c47070a commit ae31886
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/input/mpegts/iptv/iptv_rtsp.c
Expand Up @@ -19,6 +19,7 @@

#include "tvheadend.h"
#include "iptv_private.h"
#include "iptv_rtcp.h"
#include "http.h"

typedef struct {
Expand All @@ -28,6 +29,7 @@ typedef struct {
char *query;
gtimer_t alive_timer;
int play;
iptv_rtcp_info_t * rtcp_info;
} rtsp_priv_t;

/*
Expand Down Expand Up @@ -165,6 +167,9 @@ iptv_rtsp_start
}

rp = calloc(1, sizeof(*rp));
rp->rtcp_info = calloc(1, sizeof(iptv_rtcp_info_t));
rtcp_init(rp->rtcp_info);
rp->rtcp_info->connection = rtcp;
rp->hc = hc;
udp_multirecv_init(&rp->um, IPTV_PKTS, IPTV_PKT_PAYLOAD);
rp->path = strdup(u->path ?: "");
Expand Down Expand Up @@ -204,6 +209,8 @@ iptv_rtsp_stop
http_client_close(rp->hc);
free(rp->path);
free(rp->query);
rtcp_destroy(rp->rtcp_info);
free(rp->rtcp_info);
free(rp);
pthread_mutex_lock(&iptv_lock);
}
Expand Down

0 comments on commit ae31886

Please sign in to comment.