Another attempt at logging for bug 474537

This commit is contained in:
Boris Zbarsky 2009-02-02 16:27:56 -05:00
Родитель 07fb8aa41f
Коммит d7f4ad582e
2 изменённых файлов: 22 добавлений и 1 удалений

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

@ -567,6 +567,22 @@ HTMLContentSink::CreateContentObject(const nsIParserNode& aNode,
NS_ENSURE_TRUE(nodeInfo, nsnull);
if (nodeInfo->NameAtom() == nsGkAtoms::input && aNodeType != eHTMLTag_input) {
printf("BOGUS INPUT IN CreateContentObject\n");
printf("aNodeType is userdefined: %d\n", aNodeType == eHTMLTag_userdefined);
if (aNodeType == eHTMLTag_userdefined) {
printf("aNode.GetText().Length(): %d\n", aNode.GetText().Length());
printf("aNode.GetText: '%s'\n", NS_ConvertUTF16toUTF8(aNode.GetText()).get());
printf("PRUnichars: ");
for (unsigned i = 0; i < aNode.GetText().Length(); ++i) {
printf("0x%u ", (unsigned)aNode.GetText().CharAt(i));
}
printf("\n");
}
}
// Make the content object
return CreateHTMLElement(aNodeType, nodeInfo, PR_TRUE);
}
@ -603,6 +619,10 @@ already_AddRefed<nsGenericHTMLElement>
CreateHTMLElement(PRUint32 aNodeType, nsINodeInfo *aNodeInfo,
PRBool aFromParser)
{
if (aNodeInfo->NameAtom() == nsGkAtoms::input &&
aNodeType != eHTMLTag_input) {
printf("GOT INTO CreateHTMLElement WITH BOGUS INPUT\n");
}
NS_ASSERTION(aNodeType <= NS_HTML_TAG_MAX ||
aNodeType == eHTMLTag_userdefined,
"aNodeType is out of bounds");

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

@ -5074,7 +5074,8 @@ nsCSSFrameConstructor::FindInputData(nsIContent* aContent,
NS_ASSERTION(control, "input doesn't implement nsIFormControl?");
if (!control) { // Speculative parsing is screwing up somehow, dammit
return nsnull;
printf("BOGUS INPUT DETECTED IN FRAME CONSTRUCTOR\n");
// return nsnull;
}
return FindDataByInt(control->GetType(), aContent, aStyleContext,