rtspconnection: Fix potential deadlock caused by blocking read forever

Reset the connection "may_cancel" property to avoid a potential deadlock
if there is no data to read and the socket stays blocked forever.

https://bugzilla.gnome.org/show_bug.cgi?id=768249
This commit is contained in:
Sergio Torres Soldado 2016-07-04 17:19:08 +01:00 committed by Sebastian Dröge
parent 9144a787df
commit 7960bc0380

View file

@ -2161,11 +2161,13 @@ build_next (GstRTSPBuilder * builder, GstRTSPMessage * message,
}
}
done:
conn->may_cancel = TRUE;
return res;
/* ERRORS */
invalid_body_len:
{
conn->may_cancel = TRUE;
GST_DEBUG ("could not allocate body");
return GST_RTSP_ERROR;
}