Bug 1405110 - P2. Never attempts to upload to D3D11 surface in parent process. r=mattwoodrow

Accessing the graphic device driver from the parent process, should the drivers crash have serious consequences (the whole browser dies).

MozReview-Commit-ID: EXXRBnDobQw

--HG--
extra : rebase_source : d5609f1e088c7bbe92d6e46e66e1fb5538d5caac
This commit is contained in:
Jean-Yves Avenard 2017-10-09 11:10:18 +02:00
Родитель 9468ce9b28
Коммит 0de5aed9f7
1 изменённых файлов: 2 добавлений и 1 удалений

Просмотреть файл

@ -319,7 +319,8 @@ VideoData::CreateAndCopyData(const VideoInfo& aInfo,
// Currently our decoder only knows how to output to ImageFormat::PLANAR_YCBCR
// format.
#if XP_WIN
if (aAllocator && aAllocator->GetCompositorBackendType()
if (!XRE_IsParentProcess() &&
aAllocator && aAllocator->GetCompositorBackendType()
== layers::LayersBackend::LAYERS_D3D11) {
RefPtr<layers::D3D11YCbCrImage> d3d11Image = new layers::D3D11YCbCrImage();
PlanarYCbCrData data = ConstructPlanarYCbCrData(aInfo, aBuffer, aPicture);