summaryrefslogtreecommitdiff
path: root/stun/tools/stund.c
diff options
context:
space:
mode:
authorJohn Selbie <jselbie@gmail.com>2012-02-09 18:40:19 -0500
committerYouness Alaoui <youness.alaoui@collabora.co.uk>2012-02-09 18:40:19 -0500
commitdba31d4de68dfdc0186d725158251d3e36a20a99 (patch)
tree5dc634262675d01886490322651f1b74d07f80b7 /stun/tools/stund.c
parent6449dabb959c8e713c76ecf0c5eac4609c311ca2 (diff)
downloadlibnice-dba31d4de68dfdc0186d725158251d3e36a20a99.tar.gz
stund: Set message length (fixes infinite loop) when receiving unknown attributes
Diffstat (limited to 'stun/tools/stund.c')
-rw-r--r--stun/tools/stund.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/stun/tools/stund.c b/stun/tools/stund.c
index 8498318..16b7a2e 100644
--- a/stun/tools/stund.c
+++ b/stun/tools/stund.c
@@ -249,7 +249,7 @@ static int dgram_process (int sock, StunAgent *oldagent, StunAgent *newagent)
/* Unknown attributes */
if (validation == STUN_VALIDATION_UNKNOWN_REQUEST_ATTRIBUTE)
{
- stun_agent_build_unknown_attributes_error (agent, &response, buf,
+ iov.iov_len = stun_agent_build_unknown_attributes_error (agent, &response, buf,
sizeof (buf), &request);
goto send_buf;
}