Ensure box objects are obtained from the correct document b=330181 r+sr=jst

This commit is contained in:
neil%parkwaycc.co.uk 2006-03-18 14:14:08 +00:00
Родитель df160ac1f3
Коммит 06462bff40
1 изменённых файлов: 2 добавлений и 0 удалений

Просмотреть файл

@ -3217,6 +3217,8 @@ nsDocument::GetBoxObjectFor(nsIDOMElement* aElement, nsIBoxObject** aResult)
{
nsCOMPtr<nsIContent> content(do_QueryInterface(aElement));
NS_ENSURE_TRUE(content, NS_ERROR_UNEXPECTED);
NS_ENSURE_TRUE(content->GetCurrentDoc() == this,
NS_ERROR_DOM_WRONG_DOCUMENT_ERR);
nsresult rv;