summaryrefslogtreecommitdiff
path: root/agent
diff options
context:
space:
mode:
authorJakub Adam <jakub.adam@collabora.com>2018-12-14 10:45:37 +0100
committerJakub Adam <jakub.adam@collabora.com>2018-12-14 10:59:30 +0100
commited70ea09b6b283b25d3047443c00a14c8cb29e1a (patch)
tree355de9f506239ffe36e810d81751bbf8c78af80a /agent
parentbeea9b38be4efb5723d75d63d5a63241efd505cb (diff)
downloadlibnice-ed70ea09b6b283b25d3047443c00a14c8cb29e1a.tar.gz
agent: Don't require stream names to parse remote SDP
The streams are matched by the order in which they appear in the SDP, not by name, so insisting on local streams to have one makes no sense. This likely should have been removed in 5972db0.
Diffstat (limited to 'agent')
-rw-r--r--agent/agent.c11
-rw-r--r--agent/agent.h9
2 files changed, 1 insertions, 19 deletions
diff --git a/agent/agent.c b/agent/agent.c
index c4de0af..12448f3 100644
--- a/agent/agent.c
+++ b/agent/agent.c
@@ -6211,7 +6211,7 @@ nice_agent_parse_remote_sdp (NiceAgent *agent, const gchar *sdp)
{
NiceStream *current_stream = NULL;
gchar **sdp_lines = NULL;
- GSList *l, *stream_item = NULL;
+ GSList *stream_item = NULL;
gint i;
gint ret = 0;
@@ -6220,15 +6220,6 @@ nice_agent_parse_remote_sdp (NiceAgent *agent, const gchar *sdp)
agent_lock (agent);
- for (l = agent->streams; l; l = l->next) {
- NiceStream *stream = l->data;
-
- if (stream->name == NULL) {
- ret = -1;
- goto done;
- }
- }
-
sdp_lines = g_strsplit (sdp, "\n", 0);
for (i = 0; sdp_lines && sdp_lines[i]; i++) {
if (g_str_has_prefix (sdp_lines[i], "m=")) {
diff --git a/agent/agent.h b/agent/agent.h
index 520c4c5..93c835e 100644
--- a/agent/agent.h
+++ b/agent/agent.h
@@ -1487,15 +1487,6 @@ nice_agent_generate_local_candidate_sdp (
* Parse an SDP string and extracts candidates and credentials from it and sets
* them on the agent.
*
- <note>
- <para>
- This function will return an error if a stream has not been assigned a name
- with nice_agent_set_stream_name() as it becomes troublesome to assign the
- streams from the agent to the streams in the SDP.
- </para>
- </note>
- *
- *
* <para>See also: nice_agent_set_stream_name() </para>
* <para>See also: nice_agent_generate_local_sdp() </para>
* <para>See also: nice_agent_parse_remote_stream_sdp() </para>