Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
libnice
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
libnice
Commits
5bbed7e4
Commit
5bbed7e4
authored
Apr 15, 2014
by
Olivier Crête
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
agent: Add nice_agent_restart_stream() to restart a single stream
parent
28ab0b50
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
50 additions
and
1 deletion
+50
-1
agent/agent.c
agent/agent.c
+26
-1
agent/agent.h
agent/agent.h
+22
-0
docs/reference/libnice/libnice-sections.txt
docs/reference/libnice/libnice-sections.txt
+1
-0
nice/libnice.sym
nice/libnice.sym
+1
-0
No files found.
agent/agent.c
View file @
5bbed7e4
...
@@ -3689,7 +3689,6 @@ nice_agent_get_remote_candidates (
...
@@ -3689,7 +3689,6 @@ nice_agent_get_remote_candidates (
return
ret
;
return
ret
;
}
}
gboolean
gboolean
nice_agent_restart
(
nice_agent_restart
(
NiceAgent
*
agent
)
NiceAgent
*
agent
)
...
@@ -3713,6 +3712,32 @@ nice_agent_restart (
...
@@ -3713,6 +3712,32 @@ nice_agent_restart (
return
TRUE
;
return
TRUE
;
}
}
gboolean
nice_agent_restart_stream
(
NiceAgent
*
agent
,
guint
stream_id
)
{
gboolean
res
=
FALSE
;
Stream
*
stream
;
agent_lock
();
stream
=
agent_find_stream
(
agent
,
stream_id
);
if
(
!
stream
)
{
g_warning
(
"Could not find stream %u"
,
stream_id
);
goto
done
;
}
/* step: reset local credentials for the stream and
* clean up the list of remote candidates */
stream_restart
(
agent
,
stream
,
agent
->
rng
);
res
=
TRUE
;
done:
agent_unlock_and_emit
(
agent
);
return
res
;
}
static
void
static
void
nice_agent_dispose
(
GObject
*
object
)
nice_agent_dispose
(
GObject
*
object
)
...
...
agent/agent.h
View file @
5bbed7e4
...
@@ -787,6 +787,28 @@ gboolean
...
@@ -787,6 +787,28 @@ gboolean
nice_agent_restart
(
nice_agent_restart
(
NiceAgent
*
agent
);
NiceAgent
*
agent
);
/**
* nice_agent_restart_stream:
* @agent: The #NiceAgent Object
* @stream_id: The ID of the stream
*
* Restarts a single stream as defined in RFC 5245. This function
* needs to be called both when initiating (ICE spec section 9.1.1.1.
* "ICE Restarts"), as well as when reacting (spec section 9.2.1.1.
* "Detecting ICE Restart") to a restart.
*
* Unlike nice_agent_restart(), this applies to a single stream. It also
* does not generate a new tie breaker.
*
* Returns: %TRUE on success %FALSE on error
*
* Since: 0.1.6
**/
gboolean
nice_agent_restart_stream
(
NiceAgent
*
agent
,
guint
stream_id
);
/**
/**
* nice_agent_attach_recv:
* nice_agent_attach_recv:
...
...
docs/reference/libnice/libnice-sections.txt
View file @
5bbed7e4
...
@@ -36,6 +36,7 @@ nice_agent_set_selected_remote_candidate
...
@@ -36,6 +36,7 @@ nice_agent_set_selected_remote_candidate
nice_agent_set_stream_tos
nice_agent_set_stream_tos
nice_agent_set_software
nice_agent_set_software
nice_agent_restart
nice_agent_restart
nice_agent_restart_stream
nice_agent_set_stream_name
nice_agent_set_stream_name
nice_agent_get_stream_name
nice_agent_get_stream_name
nice_agent_get_default_local_candidate
nice_agent_get_default_local_candidate
...
...
nice/libnice.sym
View file @
5bbed7e4
...
@@ -41,6 +41,7 @@ nice_agent_parse_remote_sdp
...
@@ -41,6 +41,7 @@ nice_agent_parse_remote_sdp
nice_agent_parse_remote_stream_sdp
nice_agent_parse_remote_stream_sdp
nice_agent_remove_stream
nice_agent_remove_stream
nice_agent_restart
nice_agent_restart
nice_agent_restart_stream
nice_agent_send
nice_agent_send
nice_agent_send_messages_nonblocking
nice_agent_send_messages_nonblocking
nice_agent_set_port_range
nice_agent_set_port_range
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment