[Pkg-telepathy-commits] [libnice] 34/265: conncheck: Avoid reading null username
Simon McVittie
smcv at debian.org
Wed May 14 12:04:50 UTC 2014
This is an automated email from the git hooks/post-receive script.
smcv pushed a commit to branch debian
in repository libnice.
commit cbf17adaf710323ad96d641eb1e7651233deb4b4
Author: Olivier Crête <olivier.crete at collabora.com>
Date: Mon Dec 23 18:00:36 2013 -0500
conncheck: Avoid reading null username
---
agent/conncheck.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/agent/conncheck.c b/agent/conncheck.c
index 245fcb4..7be7b07 100644
--- a/agent/conncheck.c
+++ b/agent/conncheck.c
@@ -2664,7 +2664,8 @@ static bool conncheck_stun_validater (StunAgent *agent,
stun_debug ("' (%d) with '", username_len);
stun_debug_bytes (ufrag, ufrag_len);
stun_debug ("' (%" G_GSIZE_FORMAT ") : %d\n",
- ufrag_len, memcmp (username, ufrag, ufrag_len));
+ ufrag_len, username_len >= ufrag_len ?
+ memcmp (username, ufrag, ufrag_len) : 0);
if (ufrag_len > 0 && username_len >= ufrag_len &&
memcmp (username, ufrag, ufrag_len) == 0) {
gchar *pass = NULL;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-telepathy/libnice.git
More information about the Pkg-telepathy-commits
mailing list