Catch the case where the content node for the Input has not been created yet, prevent crash. b=123914 r=jkeiser, sr=roc+moz, a=asa (OBO drivers)
git-svn-id: svn://10.0.0.236/trunk@116604 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -175,7 +175,8 @@ nsIsIndexFrame::GetInputFrame(nsIPresContext* aPresContext,
|
||||
{
|
||||
nsCOMPtr<nsIPresShell> presShell;
|
||||
aPresContext->GetShell(getter_AddRefs(presShell));
|
||||
if (presShell) {
|
||||
if (!mInputContent) NS_WARNING("null content - cannot restore state");
|
||||
if (presShell && mInputContent) {
|
||||
nsIFrame *frame;
|
||||
presShell->GetPrimaryFrameFor(mInputContent, &frame);
|
||||
if (frame) {
|
||||
|
||||
@@ -175,7 +175,8 @@ nsIsIndexFrame::GetInputFrame(nsIPresContext* aPresContext,
|
||||
{
|
||||
nsCOMPtr<nsIPresShell> presShell;
|
||||
aPresContext->GetShell(getter_AddRefs(presShell));
|
||||
if (presShell) {
|
||||
if (!mInputContent) NS_WARNING("null content - cannot restore state");
|
||||
if (presShell && mInputContent) {
|
||||
nsIFrame *frame;
|
||||
presShell->GetPrimaryFrameFor(mInputContent, &frame);
|
||||
if (frame) {
|
||||
|
||||
Reference in New Issue
Block a user