From 8f49984fce4675e2e2374e99acff4a2572dca4b9 Mon Sep 17 00:00:00 2001 From: Marco Zehe Date: Tue, 24 Jun 2008 22:46:32 +0200 Subject: [PATCH] bug 441610 - Calling getAttributes() on a defunct object crashes Thunderbird, r=aaronlev --- accessible/src/base/nsAccessible.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/accessible/src/base/nsAccessible.cpp b/accessible/src/base/nsAccessible.cpp index 521a492f3e7..d44695c2fc1 100644 --- a/accessible/src/base/nsAccessible.cpp +++ b/accessible/src/base/nsAccessible.cpp @@ -2045,6 +2045,9 @@ nsAccessible::GetAttributes(nsIPersistentProperties **aAttributes) { NS_ENSURE_ARG_POINTER(aAttributes); // In/out param. Created if necessary. + if (IsDefunct()) + return NS_ERROR_FAILURE; + nsCOMPtr content = GetRoleContent(mDOMNode); if (!content) { return NS_ERROR_FAILURE;