Commit 79559c29 authored by Youness Alaoui's avatar Youness Alaoui

Make sure key len is set to 0 if key is NULL

parent dcf203e0
...@@ -2081,11 +2081,13 @@ gboolean conn_check_handle_inbound_stun (NiceAgent *agent, Stream *stream, ...@@ -2081,11 +2081,13 @@ gboolean conn_check_handle_inbound_stun (NiceAgent *agent, Stream *stream,
component->id, remote_candidate2, local_candidate, component->id, remote_candidate2, local_candidate,
uname, sizeof (uname), FALSE); uname, sizeof (uname), FALSE);
memcpy (username, uname, username_len); memcpy (username, uname, username_len);
if (remote_candidate2) if (remote_candidate2) {
req.key = g_base64_decode ((gchar *) remote_candidate2->password, req.key = g_base64_decode ((gchar *) remote_candidate2->password,
&req.key_len); &req.key_len);
else } else {
req.key = NULL; req.key = NULL;
req.key_len = 0;
}
} }
rbuf_len = sizeof (rbuf); rbuf_len = sizeof (rbuf);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment