Fix for bug 236408 (deCOMtaminate nsINodeInfoManager). r=caillon, sr=jst.

This commit is contained in:
peterv%propagandism.org 2005-11-02 07:42:24 +00:00
parent 987b09c530
commit f7932dc015
5 changed files with 7 additions and 3 deletions

View File

@ -250,7 +250,7 @@ PRBool URIUtils::CanCallerAccess(nsIDOMNode *aNode)
// nsIContent (which is important performance wise) and if that QI
// fails we QI to nsIDocument. If both those QI's fail we won't let
// the caller access this unknown node.
nsCOMPtr<nsIPrincipal> principal;
nsIPrincipal *principal = nsnull;
nsCOMPtr<nsIContent> content = do_QueryInterface(aNode);
nsCOMPtr<nsIAttribute> attr;
nsCOMPtr<nsIDocument> doc;
@ -289,8 +289,7 @@ PRBool URIUtils::CanCallerAccess(nsIDOMNode *aNode)
return PR_TRUE;
}
ni->GetDocumentPrincipal(getter_AddRefs(principal));
principal = ni->GetDocumentPrincipal();
if (!principal) {
// we can't get to the principal so we'll give up and give the
// caller access

View File

@ -46,6 +46,7 @@
#include "txCore.h"
#include "nsCOMPtr.h"
#include "nsDependentSubstring.h"
#include "nsIAtom.h"
#include "txXPathNode.h"
#ifndef TX_EXE

View File

@ -38,6 +38,7 @@
#include "nsXPathEvaluator.h"
#include "nsCOMPtr.h"
#include "nsIAtom.h"
#include "nsIDOMClassInfo.h"
#include "nsXPathException.h"
#include "nsXPathExpression.h"
@ -51,6 +52,7 @@
#include "nsIDocument.h"
#include "nsIDOMDocument.h"
#include "nsDOMString.h"
#include "nsINameSpaceManager.h"
#include "txError.h"
extern nsINameSpaceManager* gTxNameSpaceManager;

View File

@ -37,6 +37,7 @@
* ***** END LICENSE BLOCK ***** */
#include "Expr.h"
#include "nsIAtom.h"
#include "txAtoms.h"
#include "txXPathTreeWalker.h"
#include "txIXPathContext.h"

View File

@ -37,6 +37,7 @@
* ***** END LICENSE BLOCK ***** */
#include "Expr.h"
#include "nsIAtom.h"
#include "txNodeSet.h"
#include "txAtoms.h"
#include "txIXPathContext.h"