mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 671970 - Crash [@ nsPrintEngine::ReflowDocList, r=roc
This commit is contained in:
parent
9a4ea1e878
commit
f43bccee76
@ -1829,13 +1829,11 @@ nsPrintEngine::ReflowDocList(nsPrintObject* aPO, PRBool aSetPixelScale)
|
||||
|
||||
// Check to see if the subdocument's element has been hidden by the parent document
|
||||
if (aPO->mParent && aPO->mParent->mPresShell) {
|
||||
nsIFrame * frame = aPO->mContent->GetPrimaryFrame();
|
||||
if (frame) {
|
||||
if (!frame->GetStyleVisibility()->IsVisible()) {
|
||||
aPO->mDontPrint = PR_TRUE;
|
||||
aPO->mInvisible = PR_TRUE;
|
||||
return NS_OK;
|
||||
}
|
||||
nsIFrame* frame = aPO->mContent ? aPO->mContent->GetPrimaryFrame() : nsnull;
|
||||
if (!frame || !frame->GetStyleVisibility()->IsVisible()) {
|
||||
aPO->mDontPrint = PR_TRUE;
|
||||
aPO->mInvisible = PR_TRUE;
|
||||
return NS_OK;
|
||||
}
|
||||
}
|
||||
|
||||
@ -1885,7 +1883,7 @@ nsPrintEngine::ReflowPrintObject(nsPrintObject * aPO)
|
||||
nsIView* parentView = nsnull;
|
||||
|
||||
if (aPO->mParent && aPO->mParent->IsPrintable()) {
|
||||
nsIFrame* frame = aPO->mContent->GetPrimaryFrame();
|
||||
nsIFrame* frame = aPO->mContent ? aPO->mContent->GetPrimaryFrame() : nsnull;
|
||||
// Without a frame, this document can't be displayed; therefore, there is no
|
||||
// point to reflowing it
|
||||
if (!frame) {
|
||||
|
Loading…
Reference in New Issue
Block a user