get wallet editor working again after someone changed behavior of docURL

git-svn-id: svn://10.0.0.236/trunk@30954 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
morse%netscape.com
1999-05-10 20:53:35 +00:00
parent f546c6ff6b
commit fa83640928

View File

@@ -770,16 +770,18 @@ void nsFormFrame::ProcessAsURLEncoded(PRBool isPost, nsString& aData, nsIFormCon
nsIDocument* doc = nsnull;
mContent->GetDocument(doc);
while (doc && !docURL) {
const char* spec;
while (doc) {
docURL = doc->GetDocumentURL();
if (!docURL) {
doc = GetParentHTMLFrameDocument(doc);
if (!doc) break;
if (nsnull != docURL) {
(void)docURL->GetSpec(&spec);
if (PL_strcmp(spec, "about:blank")) {
break;
}
}
doc = GetParentHTMLFrameDocument(doc);
}
if (nsnull != docURL) {
const char* spec;
(void)docURL->GetSpec(&spec);
URLName = (char*)PR_Malloc(PL_strlen(spec)+1);
PL_strcpy(URLName, spec);
NS_IF_RELEASE(docURL);