Bug 492961 - Crash [@ nsHTMLTableHeaderAccessible::GetRoleInternal(unsigned int*) ], r=marcoz, davidb

This commit is contained in:
Alexander Surkov 2009-11-10 14:12:15 +08:00
parent 4fe3532b6f
commit 24fa621411

View File

@ -403,6 +403,8 @@ nsHTMLTableHeaderCellAccessible::GetRoleInternal(PRUint32 *aRole)
// Assume it's columnheader if there are headers in siblings, oterwise
// rowheader.
nsIContent* parent = content->GetParent();
NS_ENSURE_STATE(parent);
PRInt32 indexInParent = parent->IndexOf(content);
for (PRInt32 idx = indexInParent - 1; idx >= 0; idx--) {