Bug 1626570 - Improve handling of copying arrays in dom/webgpu/. r=kvark

Differential Revision: https://phabricator.services.mozilla.com/D73666
This commit is contained in:
Simon Giesecke 2020-05-06 11:42:53 +00:00
parent 5dce187722
commit 997dbb2670
2 changed files with 2 additions and 2 deletions

View File

@ -425,7 +425,7 @@ RawId WebGPUChild::DeviceCreateRenderPipeline(
if (!vertex_desc.IsNull()) {
vb_desc = ConvertVertexBufferLayoutDescriptor(vertex_desc.Value());
}
desc.mVertexState.mVertexBuffers.AppendElement(vb_desc);
desc.mVertexState.mVertexBuffers.AppendElement(std::move(vb_desc));
}
desc.mSampleCount = aDesc.mSampleCount;
desc.mSampleMask = aDesc.mSampleMask;

View File

@ -553,7 +553,7 @@ ipc::IPCResult WebGPUParent::RecvDeviceCreateSwapChain(
auto textureHost = new layers::MemoryTextureHost(
textureHostData, aDesc, layers::TextureFlags::NO_FLAGS);
textureHost->CreateRenderTexture(aExternalId);
nsTArray<RawId> bufferIds(aBufferIds);
nsTArray<RawId> bufferIds(aBufferIds.Clone());
RefPtr<PresentationData> data = new PresentationData();
data->mDeviceId = aSelfId;
data->mQueueId = aQueueId;