Bug 603586 - input.list shouldn't return the element associated with the id if it's not a datalist element. r+a=bz

This commit is contained in:
Mounir Lamouri 2010-10-12 18:25:31 +02:00
Родитель 43f0f43519
Коммит 22b9825506
1 изменённых файлов: 1 добавлений и 1 удалений

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

@ -1117,7 +1117,7 @@ nsHTMLInputElement::GetList(nsIDOMHTMLElement** aValue)
if (doc) { if (doc) {
Element* elem = doc->GetElementById(dataListId); Element* elem = doc->GetElementById(dataListId);
if (elem) { if (elem && elem->IsHTML(nsGkAtoms::datalist)) {
CallQueryInterface(elem, aValue); CallQueryInterface(elem, aValue);
return NS_OK; return NS_OK;
} }