Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Parse RTCP server port, it is mandatory to send RTCP reports
  • Loading branch information
Glandos authored and perexg committed Jun 2, 2015
1 parent ae31886 commit 768b008
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/http.h
Expand Up @@ -319,6 +319,7 @@ struct http_client {
char *hc_rtp_dest;
int hc_rtp_port;
int hc_rtpc_port;
int hc_rtcp_server_port;
int hc_rtp_multicast:1;
long hc_rtsp_stream_id;
int hc_rtp_timeout;
Expand Down
10 changes: 10 additions & 0 deletions src/rtsp.c
Expand Up @@ -170,6 +170,16 @@ rtsp_setup_decode( http_client_t *hc, int satip )
return -EIO;
}
}
else if (strncmp(argv[i], "server_port=", 12) == 0) {
j = http_tokenize(argv[i] + 12, argv2, 2, '-');
if (j > 1) {
hc->hc_rtcp_server_port = atoi(argv2[1]);
if (hc->hc_rtcp_server_port <= 0)
return -EIO;
} else {
return -EIO;
}
}
}
return HTTP_CON_OK;
}
Expand Down

0 comments on commit 768b008

Please sign in to comment.