Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
libnice
libnice
Commits
c968f3b9
Commit
c968f3b9
authored
Oct 10, 2007
by
Kai Vehmanen
Browse files
Added max-connectivity-checks property to NiceAgent.
darcs-hash:20071010114557-77cd4-07e66376fc8cffff8d2cb1eb50434f8c2a07d0b8.gz
parent
6fb31e65
Changes
2
Hide whitespace changes
Inline
Side-by-side
agent/agent-priv.h
View file @
c968f3b9
...
...
@@ -72,6 +72,7 @@ struct _NiceAgent
guint
turn_server_port
;
/**< property: TURN server port */
gboolean
controlling_mode
;
/**< property: controlling-mode */
guint
timer_ta
;
/**< property: timer Ta */
guint
max_conn_checks
;
/**< property: max connectivity checks */
GSList
*
local_addresses
;
/**< list of NiceAddresses for local
interfaces */
...
...
agent/agent.c
View file @
c968f3b9
...
...
@@ -80,7 +80,8 @@ enum
PROP_TURN_SERVER_PORT
,
PROP_CONTROLLING_MODE
,
PROP_FULL_MODE
,
PROP_STUN_PACING_TIMER
PROP_STUN_PACING_TIMER
,
PROP_MAX_CONNECTIVITY_CHECKS
};
...
...
@@ -237,6 +238,16 @@ nice_agent_class_init (NiceAgentClass *klass)
NICE_AGENT_TIMER_TA_DEFAULT
,
G_PARAM_READWRITE
|
G_PARAM_CONSTRUCT_ONLY
));
/* note: according to spec recommendation in sect 5.7.3 (ID-18) */
g_object_class_install_property
(
gobject_class
,
PROP_MAX_CONNECTIVITY_CHECKS
,
g_param_spec_uint
(
"max-connectivity-checks"
,
"Maximum number of connectivity checks"
,
"Upper limit for the total number of connectivity checks performed"
,
0
,
0xffffffff
,
0
,
/* default set in init */
G_PARAM_READWRITE
));
/* install signals */
/* signature: void cb(NiceAgent *agent, guint stream_id, guint component_id, guint state, gpointer self) */
...
...
@@ -348,6 +359,7 @@ nice_agent_init (NiceAgent *agent)
agent
->
stun_server_port
=
IPPORT_STUN
;
agent
->
turn_server_port
=
IPPORT_STUN
;
agent
->
controlling_mode
=
TRUE
;
agent
->
max_conn_checks
=
NICE_AGENT_MAX_CONNECTIVITY_CHECKS_DEFAULT
;
agent
->
discovery_list
=
NULL
;
agent
->
discovery_unsched_items
=
0
;
...
...
@@ -420,6 +432,11 @@ nice_agent_get_property (
g_value_set_uint
(
value
,
agent
->
timer_ta
);
break
;
case
PROP_MAX_CONNECTIVITY_CHECKS
:
g_value_set_uint
(
value
,
agent
->
max_conn_checks
);
/* XXX: should we prune the list of already existing checks? */
break
;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID
(
object
,
property_id
,
pspec
);
}
...
...
@@ -465,6 +482,10 @@ nice_agent_set_property (
agent
->
timer_ta
=
g_value_get_uint
(
value
);
break
;
case
PROP_MAX_CONNECTIVITY_CHECKS
:
agent
->
max_conn_checks
=
g_value_get_uint
(
value
);
break
;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID
(
object
,
property_id
,
pspec
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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