mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-26 12:20:56 +00:00
Bug 914026 - Check mDocShell before use. r=khuey
This commit is contained in:
parent
2a7fa06571
commit
8ca5dfcb54
@ -5999,7 +5999,7 @@ nsGlobalWindow::ResizeTo(int32_t aWidth, int32_t aHeight)
|
||||
* If caller is a browser-element then dispatch a resize event to
|
||||
* the embedder.
|
||||
*/
|
||||
if (mDocShell->GetIsBrowserOrApp()) {
|
||||
if (mDocShell && mDocShell->GetIsBrowserOrApp()) {
|
||||
nsIntSize size(aWidth, aHeight);
|
||||
if (!DispatchResizeEvent(size)) {
|
||||
// The embedder chose to prevent the default action for this
|
||||
@ -6039,7 +6039,7 @@ nsGlobalWindow::ResizeBy(int32_t aWidthDif, int32_t aHeightDif)
|
||||
* If caller is a browser-element then dispatch a resize event to
|
||||
* parent.
|
||||
*/
|
||||
if (mDocShell->GetIsBrowserOrApp()) {
|
||||
if (mDocShell && mDocShell->GetIsBrowserOrApp()) {
|
||||
CSSIntSize size;
|
||||
nsresult rv = GetInnerSize(size);
|
||||
NS_ENSURE_SUCCESS(rv, NS_OK);
|
||||
|
Loading…
x
Reference in New Issue
Block a user