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
b48f8e6c
Commit
b48f8e6c
authored
Dec 13, 2010
by
Youness Alaoui
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix indentation issues
parent
cb29f9e7
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
221 additions
and
221 deletions
+221
-221
socket/turn.c
socket/turn.c
+187
-187
stun/usages/turn.c
stun/usages/turn.c
+34
-34
No files found.
socket/turn.c
View file @
b48f8e6c
This diff is collapsed.
Click to expand it.
stun/usages/turn.c
View file @
b48f8e6c
...
...
@@ -106,7 +106,7 @@ size_t stun_usage_turn_create (StunAgent *agent, StunMessage *msg,
}
if
((
compatibility
==
STUN_USAGE_TURN_COMPATIBILITY_DRAFT9
||
compatibility
==
STUN_USAGE_TURN_COMPATIBILITY_RFC5766
)
&&
compatibility
==
STUN_USAGE_TURN_COMPATIBILITY_RFC5766
)
&&
request_props
!=
STUN_USAGE_TURN_REQUEST_PORT_NORMAL
)
{
uint32_t
req
=
0
;
...
...
@@ -223,40 +223,40 @@ size_t stun_usage_turn_create_permission (StunAgent *agent, StunMessage *msg,
struct
sockaddr
*
peer
,
StunUsageTurnCompatibility
compatibility
)
{
stun_agent_init_request
(
agent
,
msg
,
buffer
,
buffer_len
,
STUN_CREATEPERMISSION
);
stun_agent_init_request
(
agent
,
msg
,
buffer
,
buffer_len
,
STUN_CREATEPERMISSION
);
/* PEER address */
if
(
peer
)
{
if
(
stun_message_append_xor_addr
(
msg
,
STUN_ATTRIBUTE_XOR_PEER_ADDRESS
,
/* PEER address */
if
(
peer
)
{
if
(
stun_message_append_xor_addr
(
msg
,
STUN_ATTRIBUTE_XOR_PEER_ADDRESS
,
peer
,
sizeof
(
*
peer
))
!=
STUN_MESSAGE_RETURN_SUCCESS
)
{
return
0
;
}
}
/* nonce */
if
(
nonce
!=
NULL
)
{
if
(
stun_message_append_bytes
(
msg
,
STUN_ATTRIBUTE_NONCE
,
nonce
,
nonce_len
)
!=
STUN_MESSAGE_RETURN_SUCCESS
)
return
0
;
}
/* realm */
if
(
realm
!=
NULL
)
{
if
(
stun_message_append_bytes
(
msg
,
STUN_ATTRIBUTE_REALM
,
realm
,
realm_len
)
!=
STUN_MESSAGE_RETURN_SUCCESS
)
return
0
;
}
/* username */
if
(
username
!=
NULL
)
{
if
(
stun_message_append_bytes
(
msg
,
STUN_ATTRIBUTE_USERNAME
,
username
,
username_len
)
!=
STUN_MESSAGE_RETURN_SUCCESS
)
return
0
;
}
stun_debug
(
"before stun_agent_finish_message
\n
"
);
return
stun_agent_finish_message
(
agent
,
msg
,
password
,
password_len
);
return
0
;
}
}
/* nonce */
if
(
nonce
!=
NULL
)
{
if
(
stun_message_append_bytes
(
msg
,
STUN_ATTRIBUTE_NONCE
,
nonce
,
nonce_len
)
!=
STUN_MESSAGE_RETURN_SUCCESS
)
return
0
;
}
/* realm */
if
(
realm
!=
NULL
)
{
if
(
stun_message_append_bytes
(
msg
,
STUN_ATTRIBUTE_REALM
,
realm
,
realm_len
)
!=
STUN_MESSAGE_RETURN_SUCCESS
)
return
0
;
}
/* username */
if
(
username
!=
NULL
)
{
if
(
stun_message_append_bytes
(
msg
,
STUN_ATTRIBUTE_USERNAME
,
username
,
username_len
)
!=
STUN_MESSAGE_RETURN_SUCCESS
)
return
0
;
}
stun_debug
(
"before stun_agent_finish_message
\n
"
);
return
stun_agent_finish_message
(
agent
,
msg
,
password
,
password_len
);
}
...
...
@@ -339,7 +339,7 @@ StunUsageTurnReturn stun_usage_turn_process (StunMessage *msg,
return
STUN_USAGE_TURN_RETURN_ERROR
;
}
}
else
if
(
compatibility
==
STUN_USAGE_TURN_COMPATIBILITY_MSN
||
compatibility
==
STUN_USAGE_TURN_COMPATIBILITY_OC2007
)
{
compatibility
==
STUN_USAGE_TURN_COMPATIBILITY_OC2007
)
{
val
=
stun_message_find_addr
(
msg
,
STUN_ATTRIBUTE_MSN_MAPPED_ADDRESS
,
addr
,
addrlen
);
...
...
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