From 7ce5340ccac26496aa8eeb5982d9c3ef88da3efe Mon Sep 17 00:00:00 2001 From: Daniel Holbert Date: Fri, 26 Mar 2010 20:55:30 -0700 Subject: [PATCH] Bug 555321: In nsSVGSVGElement::InvalidateTransformNotifyFrame, don't warn about 'wrong frame type' if we don't have a frame. r=jwatt --- content/svg/content/src/nsSVGSVGElement.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/content/svg/content/src/nsSVGSVGElement.cpp b/content/svg/content/src/nsSVGSVGElement.cpp index 8d6324dd6684..56b8070e3785 100644 --- a/content/svg/content/src/nsSVGSVGElement.cpp +++ b/content/svg/content/src/nsSVGSVGElement.cpp @@ -1091,15 +1091,15 @@ nsSVGSVGElement::WillBeOutermostSVG(nsIContent* aParent, void nsSVGSVGElement::InvalidateTransformNotifyFrame() { - nsISVGSVGFrame* svgframe = do_QueryFrame(GetPrimaryFrame()); + nsIFrame* frame = GetPrimaryFrame(); + nsISVGSVGFrame* svgframe = do_QueryFrame(frame); if (svgframe) { svgframe->NotifyViewportChange(); } #ifdef DEBUG - else { - // XXX we get here during nsSVGOuterSVGFrame::Init() since that - // function is called before the presshell association between us - // and our frame is established. + else if (frame) { + // Uh oh -- we have a primary frame, but it failed the do_QueryFrame to the + // expected type! NS_WARNING("wrong frame type"); } #endif