mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-25 19:25:43 +00:00
Bug 1152046 - Disable ClosingService for Firefox OS. r=mcmanus
--HG-- extra : rebase_source : fc005bccf525a785e9b87d47236b738eb384c88e
This commit is contained in:
parent
b08e7b3457
commit
5dbbbf93f4
@ -26,6 +26,7 @@ public:
|
|||||||
namespace mozilla {
|
namespace mozilla {
|
||||||
namespace net {
|
namespace net {
|
||||||
|
|
||||||
|
#ifndef MOZ_WIDGET_GONK
|
||||||
static PRIOMethods sTcpUdpPRCloseLayerMethods;
|
static PRIOMethods sTcpUdpPRCloseLayerMethods;
|
||||||
static PRIOMethods *sTcpUdpPRCloseLayerMethodsPtr = nullptr;
|
static PRIOMethods *sTcpUdpPRCloseLayerMethodsPtr = nullptr;
|
||||||
static PRDescIdentity sTcpUdpPRCloseLayerId;
|
static PRDescIdentity sTcpUdpPRCloseLayerId;
|
||||||
@ -68,6 +69,7 @@ TcpUdpPRCloseLayerClose(PRFileDesc *aFd)
|
|||||||
delete closingLayerSecret;
|
delete closingLayerSecret;
|
||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
|
#endif //MOZ_WIDGET_GONK
|
||||||
|
|
||||||
ClosingService* ClosingService::sInstance = nullptr;
|
ClosingService* ClosingService::sInstance = nullptr;
|
||||||
|
|
||||||
@ -83,6 +85,7 @@ ClosingService::ClosingService()
|
|||||||
void
|
void
|
||||||
ClosingService::Start()
|
ClosingService::Start()
|
||||||
{
|
{
|
||||||
|
#ifndef MOZ_WIDGET_GONK
|
||||||
if (!sTcpUdpPRCloseLayerMethodsPtr) {
|
if (!sTcpUdpPRCloseLayerMethodsPtr) {
|
||||||
sTcpUdpPRCloseLayerId = PR_GetUniqueIdentity("TCP and UDP PRClose layer");
|
sTcpUdpPRCloseLayerId = PR_GetUniqueIdentity("TCP and UDP PRClose layer");
|
||||||
PR_ASSERT(PR_INVALID_IO_LAYER != sTcpUdpPRCloseLayerId);
|
PR_ASSERT(PR_INVALID_IO_LAYER != sTcpUdpPRCloseLayerId);
|
||||||
@ -101,6 +104,7 @@ ClosingService::Start()
|
|||||||
delete service;
|
delete service;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
nsresult
|
nsresult
|
||||||
@ -119,6 +123,12 @@ ClosingService::StartInternal()
|
|||||||
nsresult
|
nsresult
|
||||||
ClosingService::AttachIOLayer(PRFileDesc *aFd)
|
ClosingService::AttachIOLayer(PRFileDesc *aFd)
|
||||||
{
|
{
|
||||||
|
#ifdef MOZ_WIDGET_GONK
|
||||||
|
|
||||||
|
return NS_OK;
|
||||||
|
|
||||||
|
#else
|
||||||
|
|
||||||
if (!sTcpUdpPRCloseLayerMethodsPtr) {
|
if (!sTcpUdpPRCloseLayerMethodsPtr) {
|
||||||
return NS_OK;
|
return NS_OK;
|
||||||
}
|
}
|
||||||
@ -143,6 +153,8 @@ ClosingService::AttachIOLayer(PRFileDesc *aFd)
|
|||||||
PR_DELETE(layer);
|
PR_DELETE(layer);
|
||||||
}
|
}
|
||||||
return NS_OK;
|
return NS_OK;
|
||||||
|
|
||||||
|
#endif //MOZ_WIDGET_GONK
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -171,12 +183,14 @@ ClosingService::PostRequest(PRFileDesc *aFd)
|
|||||||
void
|
void
|
||||||
ClosingService::Shutdown()
|
ClosingService::Shutdown()
|
||||||
{
|
{
|
||||||
|
#ifndef MOZ_WIDGET_GONK
|
||||||
MOZ_ASSERT(NS_IsMainThread());
|
MOZ_ASSERT(NS_IsMainThread());
|
||||||
|
|
||||||
if (sInstance) {
|
if (sInstance) {
|
||||||
sInstance->ShutdownInternal();
|
sInstance->ShutdownInternal();
|
||||||
NS_RELEASE(sInstance);
|
NS_RELEASE(sInstance);
|
||||||
}
|
}
|
||||||
|
#endif //MOZ_WIDGET_GONK
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
Loading…
Reference in New Issue
Block a user