Commit 04181fb5 authored by Youness Alaoui's avatar Youness Alaoui

hacky trick to copy the user/pass from a candidate if we learn a...

hacky trick to copy the user/pass from a candidate if we learn a peer-reflexive candidate, that we're not in msn compat, and that the user didn't use the set_remote_credentials API
parent d31cc436
...@@ -646,6 +646,12 @@ discovery_add_peer_reflexive_candidate ( ...@@ -646,6 +646,12 @@ discovery_add_peer_reflexive_candidate (
g_free(decoded_local); g_free(decoded_local);
g_free(decoded_remote); g_free(decoded_remote);
candidate->password = g_strdup(local->password);
} else if (local) {
g_free(candidate->username);
g_free(candidate->password);
candidate->username = g_strdup(local->username);
candidate->password = g_strdup(local->password); candidate->password = g_strdup(local->password);
} }
...@@ -746,7 +752,7 @@ NiceCandidate *discovery_learn_remote_peer_reflexive_candidate ( ...@@ -746,7 +752,7 @@ NiceCandidate *discovery_learn_remote_peer_reflexive_candidate (
g_free(decoded_remote); g_free(decoded_remote);
candidate->password = g_strdup(remote->password); candidate->password = g_strdup(remote->password);
} else if (agent->compatibility == NICE_COMPATIBILITY_GOOGLE) { } else if (remote) {
g_free (candidate->username); g_free (candidate->username);
g_free (candidate->password); g_free (candidate->password);
candidate->username = g_strdup(remote->username); candidate->username = g_strdup(remote->username);
......
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