From: Andrei Emeltchenko <andrei.emeltchenko@xxxxxxxxx> Check that the full header is received in recv(). --- src/sdpd-server.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sdpd-server.c b/src/sdpd-server.c index 7b1351f..10e46a1 100644 --- a/src/sdpd-server.c +++ b/src/sdpd-server.c @@ -166,7 +166,7 @@ static gboolean io_session_event(GIOChannel *chan, GIOCondition cond, gpointer d } len = recv(sk, &hdr, sizeof(sdp_pdu_hdr_t), MSG_PEEK); - if (len <= 0) { + if (len != sizeof(sdp_pdu_hdr_t)) { sdp_svcdb_collect_all(sk); return FALSE; } -- 1.7.10.4 -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html