summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--agent/agent.c1
-rw-r--r--agent/conncheck.c2
-rw-r--r--socket/udp-turn.c5
-rw-r--r--stun/usages/bind.c4
4 files changed, 6 insertions, 6 deletions
diff --git a/agent/agent.c b/agent/agent.c
index 8ba99bc..28d7ccf 100644
--- a/agent/agent.c
+++ b/agent/agent.c
@@ -1552,7 +1552,6 @@ pseudo_tcp_socket_recv_messages (PseudoTcpSocket *self,
if (len == 0) {
/* Reached EOS. */
- len = 0;
goto done;
} else if (len < 0 &&
pseudo_tcp_socket_get_error (self) == EWOULDBLOCK) {
diff --git a/agent/conncheck.c b/agent/conncheck.c
index 7096b42..1dc13dd 100644
--- a/agent/conncheck.c
+++ b/agent/conncheck.c
@@ -606,7 +606,7 @@ static gboolean priv_conn_check_tick_unlocked (NiceAgent *agent)
/* step: when there's no pair in the Waiting state,
* unfreeze a new pair and check it
*/
- res = priv_conn_check_unfreeze_next (agent);
+ priv_conn_check_unfreeze_next (agent);
for (i = agent->streams; i ; i = i->next) {
NiceStream *stream = i->data;
diff --git a/socket/udp-turn.c b/socket/udp-turn.c
index cc3409b..a9c57e5 100644
--- a/socket/udp-turn.c
+++ b/socket/udp-turn.c
@@ -406,9 +406,8 @@ socket_recv_messages (NiceSocket *sock,
/* Split up the monolithic buffer again into the caller-provided buffers. */
if (parsed_buffer_length > 0 && allocated_buffer) {
- parsed_buffer_length =
- memcpy_buffer_to_input_message (message, buffer,
- parsed_buffer_length);
+ memcpy_buffer_to_input_message (message, buffer,
+ parsed_buffer_length);
}
if (allocated_buffer)
diff --git a/stun/usages/bind.c b/stun/usages/bind.c
index 8dd7afc..d56790f 100644
--- a/stun/usages/bind.c
+++ b/stun/usages/bind.c
@@ -479,7 +479,7 @@ StunUsageBindReturn stun_usage_bind_run (const struct sockaddr *srv,
size_t len;
StunUsageTransReturn ret;
int val;
- struct sockaddr_storage alternate_server;
+ struct sockaddr_storage alternate_server = { AF_UNSPEC } ;
socklen_t alternate_server_len = sizeof (alternate_server);
StunUsageBindReturn bind_ret;
@@ -548,6 +548,8 @@ StunUsageBindReturn stun_usage_bind_run (const struct sockaddr *srv,
if (bind_ret == STUN_USAGE_BIND_RETURN_ALTERNATE_SERVER) {
stun_trans_deinit (&trans);
+ assert (alternate_server.ss_family != AF_UNSPEC);
+
ret = stun_trans_create (&trans, SOCK_DGRAM, 0,
(struct sockaddr *) &alternate_server, alternate_server_len);