mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 06:11:37 +00:00
bug 454502: prbool issues in html parser. r+sr=mrbkap
This commit is contained in:
parent
e8ffa77fe0
commit
15ba12b39c
@ -2245,7 +2245,7 @@ CNavDTD::CanPropagate(eHTMLTags aParent, eHTMLTags aChild,
|
||||
result = PR_FALSE;
|
||||
}
|
||||
} else {
|
||||
result = aParentContains;
|
||||
result = !!aParentContains;
|
||||
}
|
||||
|
||||
|
||||
|
@ -182,7 +182,7 @@ Driver_HandleStartDoctypeDecl(void *aUserData,
|
||||
NS_ASSERTION(aUserData, "expat driver should exist");
|
||||
if (aUserData) {
|
||||
static_cast<nsExpatDriver*>(aUserData)->
|
||||
HandleStartDoctypeDecl(aDoctypeName, aSysid, aPubid, aHasInternalSubset);
|
||||
HandleStartDoctypeDecl(aDoctypeName, aSysid, aPubid, !!aHasInternalSubset);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -561,7 +561,7 @@ nsHTMLTokenizer::ConsumeTag(PRUnichar aChar,
|
||||
|
||||
// XML allows non ASCII tag names, consume this as an end tag. This
|
||||
// is needed to make XML view source work
|
||||
PRBool isXML = mFlags & NS_IPARSER_FLAG_XML;
|
||||
PRBool isXML = !!(mFlags & NS_IPARSER_FLAG_XML);
|
||||
if (nsCRT::IsAsciiAlpha(theNextChar) ||
|
||||
kGreaterThan == theNextChar ||
|
||||
(isXML && !nsCRT::IsAscii(theNextChar))) {
|
||||
@ -597,7 +597,7 @@ nsHTMLTokenizer::ConsumeTag(PRUnichar aChar,
|
||||
|
||||
default:
|
||||
// XML allows non ASCII tag names, consume this as a start tag.
|
||||
PRBool isXML = mFlags & NS_IPARSER_FLAG_XML;
|
||||
PRBool isXML = !!(mFlags & NS_IPARSER_FLAG_XML);
|
||||
if (nsCRT::IsAsciiAlpha(aChar) ||
|
||||
(isXML && !nsCRT::IsAscii(aChar))) {
|
||||
// Get the original "<" (we've already seen it with a Peek)
|
||||
|
@ -86,11 +86,11 @@ public:
|
||||
|
||||
PRBool IsXMLLetter(PRUnichar aChar)
|
||||
{
|
||||
return MOZ_XMLIsLetter(reinterpret_cast<const char*>(&aChar));
|
||||
return !!MOZ_XMLIsLetter(reinterpret_cast<const char*>(&aChar));
|
||||
}
|
||||
PRBool IsXMLNCNameChar(PRUnichar aChar)
|
||||
{
|
||||
return MOZ_XMLIsNCNameChar(reinterpret_cast<const char*>(&aChar));
|
||||
return !!MOZ_XMLIsNCNameChar(reinterpret_cast<const char*>(&aChar));
|
||||
}
|
||||
PRUint32 DecodeEntity(const PRUnichar* aStart, const PRUnichar* aEnd,
|
||||
const PRUnichar** aNext, PRUnichar* aResult)
|
||||
|
Loading…
Reference in New Issue
Block a user