summaryrefslogtreecommitdiff
path: root/gst
diff options
context:
space:
mode:
authorOlivier CrĂȘte <olivier.crete@ocrete.ca>2014-05-04 00:47:13 -0400
committerOlivier CrĂȘte <olivier.crete@ocrete.ca>2014-05-04 00:47:13 -0400
commit64bfaf6af39957996ae1114767d1f674e246fd97 (patch)
tree540daa1119066151c9c63f76471f9edb60d47654 /gst
parent3610fe76c1856f19595b8d966180444922ca4056 (diff)
downloadfarstream-64bfaf6af39957996ae1114767d1f674e246fd97.tar.gz
msnconnection: Make sure token is correctly read
Diffstat (limited to 'gst')
-rw-r--r--gst/fsmsnconference/fs-msn-connection.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/gst/fsmsnconference/fs-msn-connection.c b/gst/fsmsnconference/fs-msn-connection.c
index 17093d5c..b10619aa 100644
--- a/gst/fsmsnconference/fs-msn-connection.c
+++ b/gst/fsmsnconference/fs-msn-connection.c
@@ -830,7 +830,11 @@ connection_cb (FsMsnConnection *self, FsMsnPollFD *pollfd)
if (size == 13 && strcmp (str, "connected\r\n\r\n") == 0)
{
GST_DEBUG ("connection successful");
- recv (pollfd->pollfd.fd, str, 13, 0);
+ if (recv (pollfd->pollfd.fd, str, 13, 0) != 13) {
+ GST_WARNING ("could not read token");
+
+ goto error;
+ }
pollfd->status = FS_MSN_STATUS_SEND_RECEIVE;
success = TRUE;
}