Closed Bug 1305490 Opened 4 years ago Closed 4 years ago

D3D11TextureData::UpdateFromSurface ASSERT crashes child when used by plugin


(Core :: Graphics: Layers, defect, P3)




Tracking Status
firefox52 --- fixed


(Reporter: handyman, Assigned: sotaro)



(Keywords: crash, Whiteboard: [gfx-noted])


(3 files, 1 obsolete file)

Attached file pluginproc.txt

0. Launch Firefox x64
1. Go to

Expected Result:
The plugin plays fine.

Actual Result:


Running a debug build and connecting the debugger to the child and plugin processes shows that this assert triggers in the child process when the crash happens:

I've attached the plugin and content process stacks at the time of the crash.  The pretty clearly show the communication that led to this situation.
Attached file contentproc.txt
Has STR: --- → yes
Keywords: crash
OS: Unspecified → Windows
Priority: -- → P3
Whiteboard: [gfx-noted]
Assignee: nobody → sotaro.ikeda.g
The assert was added by bug 1289640.
Blocks: 1289640
(In reply to David Parks [:handyman] from comment #0)
> Created attachment 8794957 [details]
> pluginproc.txt
> STR:
> 0. Launch Firefox x64
> 1. Go to

I could reproduce the crash when async plugin rendering was used by flash plugin.
When TextureData::UpdateFromSurface() is not supported, TextureClient::UpdateFromSurface() fallbacks to DrawTarget approach on main thread. Plugin ipc runs on main thread, then the DrawTarget approach seems to work in this case.
Attachment #8797913 - Flags: review?(matt.woodrow)
Confirmed that attachment 8797913 [details] [diff] [review] addressed the crash.
Comment on attachment 8797913 [details] [diff] [review]
patch - Remove assert in D3D11TextureData::UpdateFromSurface()

Review of attachment 8797913 [details] [diff] [review]:

This will fix the crash, but we still won't be able to upload.

Can you please instead wait until the patch from bug 1292923 lands and then pass the ALLOC_UPDATE_FROM_SURFACE flag to make sure we get an appropriate TextureClient.
Attachment #8797913 - Flags: review?(matt.woodrow) → review-
OK, thanks!
Depends on: 1292923
Attachment #8797913 - Attachment is obsolete: true
Attachment #8799629 - Flags: review?(matt.woodrow)
Attachment #8799629 - Flags: review?(matt.woodrow) → review+
Pushed by
Use ALLOC_UPDATE_FROM_SURFACE flag r=mattwoodrow
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla52
Depends on: 1311952
Depends on: 1312988
It looks like this change introduced a regression that broke Farmville 2 Flash game on Facebook from rendering correctly. Marked that down as
Depends on: 1317984
You need to log in before you can comment on or make changes to this bug.