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
9e5d7436
Commit
9e5d7436
authored
Jan 30, 2007
by
Dafydd Harries
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
stun_attribute_username_new
darcs-hash:20070130112714-c9803-7af1e55e269dadfb83fa6447eda28fc41b9c403d.gz
parent
fabb0ad0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
0 deletions
+14
-0
stun/stun.c
stun/stun.c
+12
-0
stun/stun.h
stun/stun.h
+2
-0
No files found.
stun/stun.c
View file @
9e5d7436
...
...
@@ -38,6 +38,18 @@ stun_attribute_mapped_address_new (guint32 ip, guint16 port)
return
attr
;
}
StunAttribute
*
stun_attribute_username_new
(
const
gchar
*
username
)
{
StunAttribute
*
attr
;
attr
=
stun_attribute_new
(
STUN_ATTRIBUTE_USERNAME
);
g_assert
(
strlen
(
username
)
<
sizeof
(
attr
->
username
));
attr
->
length
=
strlen
(
username
);
strcpy
(
attr
->
username
,
username
);
return
attr
;
}
void
stun_attribute_free
(
StunAttribute
*
attr
)
{
...
...
stun/stun.h
View file @
9e5d7436
...
...
@@ -80,6 +80,8 @@ struct _StunMessage {
G_GNUC_WARN_UNUSED_RESULT
StunAttribute
*
stun_attribute_mapped_address_new
(
guint32
ip_address
,
guint16
port
);
StunAttribute
*
stun_attribute_username_new
(
const
gchar
*
username
);
void
stun_attribute_free
(
StunAttribute
*
attr
);
G_GNUC_WARN_UNUSED_RESULT
...
...
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