mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1058022 - B2G crashes during RTSP and HTTP streaming playback. r=sworkman
This commit is contained in:
parent
0c6bd09dac
commit
ea779c5af2
@ -107,7 +107,12 @@ void ARTPConnection::removeStream(PRFileDesc *rtpSocket, PRFileDesc *rtcpSocket)
|
|||||||
sp<AMessage> msg = new AMessage(kWhatRemoveStream, id());
|
sp<AMessage> msg = new AMessage(kWhatRemoveStream, id());
|
||||||
msg->setPointer("rtp-socket", rtpSocket);
|
msg->setPointer("rtp-socket", rtpSocket);
|
||||||
msg->setPointer("rtcp-socket", rtcpSocket);
|
msg->setPointer("rtcp-socket", rtcpSocket);
|
||||||
msg->post();
|
|
||||||
|
// Since the caller will close the sockets after this function
|
||||||
|
// returns, we need to use a blocking post to prevent from polling
|
||||||
|
// closed sockets.
|
||||||
|
sp<AMessage> response;
|
||||||
|
msg->postAndAwaitResponse(&response);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void bumpSocketBufferSize(PRFileDesc *s) {
|
static void bumpSocketBufferSize(PRFileDesc *s) {
|
||||||
@ -177,6 +182,10 @@ void ARTPConnection::onMessageReceived(const sp<AMessage> &msg) {
|
|||||||
case kWhatRemoveStream:
|
case kWhatRemoveStream:
|
||||||
{
|
{
|
||||||
onRemoveStream(msg);
|
onRemoveStream(msg);
|
||||||
|
sp<AMessage> ack = new AMessage;
|
||||||
|
uint32_t replyID;
|
||||||
|
CHECK(msg->senderAwaitsResponse(&replyID));
|
||||||
|
ack->postReply(replyID);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user