mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 494103 - nsXMLContentSerializer UMR during update.mar tests; r+sr=peterv
This commit is contained in:
parent
5f5ad04827
commit
1eaf91e8f7
@ -205,7 +205,7 @@ nsHTMLContentSerializer::AppendElementStart(nsIDOMElement *aElement,
|
||||
nsCOMPtr<nsIContent> content = do_QueryInterface(aElement);
|
||||
if (!content) return NS_ERROR_FAILURE;
|
||||
|
||||
PRBool forceFormat;
|
||||
PRBool forceFormat = PR_FALSE;
|
||||
if (!CheckElementStart(content, forceFormat, aStr)) {
|
||||
return NS_OK;
|
||||
}
|
||||
|
@ -898,7 +898,7 @@ nsXMLContentSerializer::AppendElementStart(nsIDOMElement *aElement,
|
||||
nsCOMPtr<nsIContent> content(do_QueryInterface(aElement));
|
||||
if (!content) return NS_ERROR_FAILURE;
|
||||
|
||||
PRBool forceFormat;
|
||||
PRBool forceFormat = PR_FALSE;
|
||||
if (!CheckElementStart(content, forceFormat, aStr)) {
|
||||
return NS_OK;
|
||||
}
|
||||
@ -1001,7 +1001,7 @@ nsXMLContentSerializer::AppendElementEnd(nsIDOMElement *aElement,
|
||||
nsCOMPtr<nsIContent> content(do_QueryInterface(aElement));
|
||||
if (!content) return NS_ERROR_FAILURE;
|
||||
|
||||
PRBool forceFormat, outputElementEnd;
|
||||
PRBool forceFormat = PR_FALSE, outputElementEnd;
|
||||
outputElementEnd = CheckElementEnd(content, forceFormat, aStr);
|
||||
|
||||
nsIAtom *name = content->Tag();
|
||||
@ -1133,11 +1133,11 @@ nsXMLContentSerializer::CheckElementEnd(nsIContent * aContent,
|
||||
// We don't output a separate end tag for empty element
|
||||
nsCOMPtr<nsIDOMNode> node(do_QueryInterface(aContent));
|
||||
PRBool hasChildren;
|
||||
aForceFormat = PR_FALSE;
|
||||
|
||||
if (NS_SUCCEEDED(node->HasChildNodes(&hasChildren)) && !hasChildren) {
|
||||
return PR_FALSE;
|
||||
}
|
||||
|
||||
aForceFormat = PR_FALSE;
|
||||
return PR_TRUE;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user