diff options
author | Kristian Monsen <kristianm@google.com> | 2011-01-31 13:31:23 +0000 |
---|---|---|
committer | Kristian Monsen <kristianm@google.com> | 2011-01-31 14:21:06 +0000 |
commit | 1d9d64a4048883a707deb9f2ec32aa311e11dcbb (patch) | |
tree | ce0fbaec5a79fb96295986e489b5f812c330edd8 /WebKit/android/nav | |
parent | c36054aacf610538d595ecc02cfbef4e6678eaa7 (diff) | |
download | external_webkit-1d9d64a4048883a707deb9f2ec32aa311e11dcbb.zip external_webkit-1d9d64a4048883a707deb9f2ec32aa311e11dcbb.tar.gz external_webkit-1d9d64a4048883a707deb9f2ec32aa311e11dcbb.tar.bz2 |
Fix for bug 3405738, crash in nav cache
Change-Id: I43c87a3b8a772857fd2775b54a68d8df6c6441ef
Diffstat (limited to 'WebKit/android/nav')
-rw-r--r-- | WebKit/android/nav/CachedFrame.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/WebKit/android/nav/CachedFrame.cpp b/WebKit/android/nav/CachedFrame.cpp index b18cdf1..27eebd3 100644 --- a/WebKit/android/nav/CachedFrame.cpp +++ b/WebKit/android/nav/CachedFrame.cpp @@ -50,11 +50,13 @@ WebCore::IntRect CachedFrame::adjustBounds(const CachedNode* node, mRoot->mViewBounds.x(), mRoot->mViewBounds.y(), mRoot->mViewBounds.width(), mRoot->mViewBounds.height()); #if USE(ACCELERATED_COMPOSITING) - const CachedLayer* cachedLayer = layer(node); - const WebCore::LayerAndroid* rootLayer = mRoot->rootLayer(); - const LayerAndroid* aLayer = cachedLayer->layer(rootLayer); - if (aLayer) - return cachedLayer->adjustBounds(rootLayer, rect); + if (mRoot) { + const CachedLayer* cachedLayer = layer(node); + const WebCore::LayerAndroid* rootLayer = mRoot->rootLayer(); + const LayerAndroid* aLayer = cachedLayer->layer(rootLayer); + if (aLayer) + return cachedLayer->adjustBounds(rootLayer, rect); + } #endif return rect; } |