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
07e82747
Commit
07e82747
authored
Jan 14, 2009
by
Youness Alaoui
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
make the NiceAgent automatically search for all the interfaces if none was set manually
parent
9e62e01f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
1 deletion
+19
-1
agent/agent.c
agent/agent.c
+19
-1
No files found.
agent/agent.c
View file @
07e82747
...
@@ -69,6 +69,7 @@
...
@@ -69,6 +69,7 @@
#include "agent-signals-marshal.h"
#include "agent-signals-marshal.h"
#include "stream.h"
#include "stream.h"
#include "interfaces.h"
/* This is the max size of a UDP packet
/* This is the max size of a UDP packet
* will it work tcp relaying??
* will it work tcp relaying??
...
@@ -1084,8 +1085,25 @@ nice_agent_gather_candidates (
...
@@ -1084,8 +1085,25 @@ nice_agent_gather_candidates (
nice_debug
(
"Agent %p : In %s mode, starting candidate gathering."
,
agent
,
nice_debug
(
"Agent %p : In %s mode, starting candidate gathering."
,
agent
,
agent
->
full_mode
?
"ICE-FULL"
:
"ICE-LITE"
);
agent
->
full_mode
?
"ICE-FULL"
:
"ICE-LITE"
);
/* generate a local host candidate for each local address */
/* if no local addresses added, generate them ourselves */
if
(
agent
->
local_addresses
==
NULL
)
{
GList
*
addresses
=
nice_interfaces_get_local_ips
(
FALSE
);
GList
*
item
;
for
(
item
=
addresses
;
item
;
item
=
g_list_next
(
item
))
{
NiceAddress
*
addr
=
nice_address_new
();
if
(
nice_address_set_from_string
(
addr
,
item
->
data
))
{
nice_agent_add_local_address
(
agent
,
addr
);
}
nice_address_free
(
addr
);
}
g_list_foreach
(
addresses
,
(
GFunc
)
g_free
,
NULL
);
g_list_free
(
addresses
);
}
/* generate a local host candidate for each local address */
for
(
i
=
agent
->
local_addresses
;
i
;
i
=
i
->
next
){
for
(
i
=
agent
->
local_addresses
;
i
;
i
=
i
->
next
){
NiceAddress
*
addr
=
i
->
data
;
NiceAddress
*
addr
=
i
->
data
;
NiceCandidate
*
host_candidate
;
NiceCandidate
*
host_candidate
;
...
...
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