Fixed SOAP document-style returns. Not part of default build.

git-svn-id: svn://10.0.0.236/trunk@109177 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
rayw%netscape.com 2001-11-29 03:31:42 +00:00
parent 831c4e6f2e
commit ad0a29b7ce
2 changed files with 14 additions and 2 deletions

View File

@ -385,11 +385,17 @@ NS_IMETHODIMP nsSOAPMessage::GetParameters(PRBool aDocumentStyle, PRUint32 *aCou
int count = 0;
int length = 0;
nsCOMPtr<nsIDOMElement> element;
nsresult rv = GetHeader(getter_AddRefs(element));
nsresult rv = GetBody(getter_AddRefs(element));
if (NS_FAILED(rv)) return rv;
if (!element) return NS_ERROR_ILLEGAL_VALUE;
nsCOMPtr<nsIDOMElement> next;
nsCOMPtr<nsISOAPParameter> param;
nsSOAPUtils::GetFirstChildElement(element, getter_AddRefs(next));
if (aDocumentStyle) {
element = next;
if (!element) return NS_ERROR_ILLEGAL_VALUE;
nsSOAPUtils::GetFirstChildElement(element, getter_AddRefs(next));
}
while (next) {
if (length == count) {
length = length ? 2 * length : 10;

View File

@ -385,11 +385,17 @@ NS_IMETHODIMP nsSOAPMessage::GetParameters(PRBool aDocumentStyle, PRUint32 *aCou
int count = 0;
int length = 0;
nsCOMPtr<nsIDOMElement> element;
nsresult rv = GetHeader(getter_AddRefs(element));
nsresult rv = GetBody(getter_AddRefs(element));
if (NS_FAILED(rv)) return rv;
if (!element) return NS_ERROR_ILLEGAL_VALUE;
nsCOMPtr<nsIDOMElement> next;
nsCOMPtr<nsISOAPParameter> param;
nsSOAPUtils::GetFirstChildElement(element, getter_AddRefs(next));
if (aDocumentStyle) {
element = next;
if (!element) return NS_ERROR_ILLEGAL_VALUE;
nsSOAPUtils::GetFirstChildElement(element, getter_AddRefs(next));
}
while (next) {
if (length == count) {
length = length ? 2 * length : 10;