Bug 635464: Diagnostic crash in nightly and aurora, to see if we are asking basic content client for alpha. r?bas
MozReview-Commit-ID: 2DBdJZs0hlh
--- a/gfx/2d/Logging.h
+++ b/gfx/2d/Logging.h
@@ -121,16 +121,17 @@ enum class LogReason : int {
MessageChannelCloseFailure,
MessageChannelInvalidHandle,
TextureAliveAfterShutdown,
InvalidContext,
InvalidCommandList,
AsyncTransactionTimeout, // 30
TextureCreation,
InvalidCacheSurface,
+ AlphaWithBasicClient,
// End
MustBeLessThanThis = 101,
};
struct BasicLogger
{
// For efficiency, this method exists and copies the logic of the
// OutputMessage below. If making any changes here, also make it
--- a/gfx/layers/client/ContentClient.cpp
+++ b/gfx/layers/client/ContentClient.cpp
@@ -122,16 +122,19 @@ ContentClientBasic::ContentClientBasic()
void
ContentClientBasic::CreateBuffer(ContentType aType,
const IntRect& aRect,
uint32_t aFlags,
RefPtr<gfx::DrawTarget>* aBlackDT,
RefPtr<gfx::DrawTarget>* aWhiteDT)
{
MOZ_ASSERT(!(aFlags & BUFFER_COMPONENT_ALPHA));
+ if (aFlags & BUFFER_COMPONENT_ALPHA) {
+ gfxDevCrash(LogReason::AlphaWithBasicClient) << "Asking basic content client for component alpha";
+ }
*aBlackDT = gfxPlatform::GetPlatform()->CreateOffscreenContentDrawTarget(
IntSize(aRect.width, aRect.height),
gfxPlatform::GetPlatform()->Optimal2DFormatForContent(aType));
}
void
ContentClientRemoteBuffer::DestroyBuffers()