Fix for bug 397386 (Large leak on grono.net front page), part 2. r/sr=sicking, a=dsicore.

This commit is contained in:
peterv%propagandism.org 2007-09-27 16:39:13 +00:00
Родитель 42ed3047eb
Коммит fad2d56600
4 изменённых файлов: 19 добавлений и 8 удалений

Просмотреть файл

@ -49,9 +49,13 @@
#include "txURIUtils.h"
#include "txXPathTreeWalker.h"
NS_IMPL_ADDREF(nsXPathExpression)
NS_IMPL_RELEASE(nsXPathExpression)
NS_INTERFACE_MAP_BEGIN(nsXPathExpression)
NS_IMPL_CYCLE_COLLECTION_1(nsXPathExpression, mDocument)
NS_IMPL_CYCLE_COLLECTING_ADDREF_AMBIGUOUS(nsXPathExpression,
nsIDOMXPathExpression)
NS_IMPL_CYCLE_COLLECTING_RELEASE_AMBIGUOUS(nsXPathExpression,
nsIDOMXPathExpression)
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(nsXPathExpression)
NS_INTERFACE_MAP_ENTRY(nsIDOMXPathExpression)
NS_INTERFACE_MAP_ENTRY(nsIDOMNSXPathExpression)
NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIDOMXPathExpression)

Просмотреть файл

@ -44,6 +44,7 @@
#include "txIXPathContext.h"
#include "txResultRecycler.h"
#include "nsAutoPtr.h"
#include "nsCycleCollectionParticipant.h"
class Expr;
class txXPathNode;
@ -59,7 +60,9 @@ public:
nsIDOMDocument *aDocument);
// nsISupports interface
NS_DECL_ISUPPORTS
NS_DECL_CYCLE_COLLECTING_ISUPPORTS
NS_DECL_CYCLE_COLLECTION_CLASS_AMBIGUOUS(nsXPathExpression,
nsIDOMXPathExpression)
// nsIDOMXPathExpression interface
NS_DECL_NSIDOMXPATHEXPRESSION

Просмотреть файл

@ -41,9 +41,11 @@
#include "nsDOMString.h"
#include "nsContentUtils.h"
NS_IMPL_ADDREF(nsXPathNSResolver)
NS_IMPL_RELEASE(nsXPathNSResolver)
NS_INTERFACE_MAP_BEGIN(nsXPathNSResolver)
NS_IMPL_CYCLE_COLLECTION_1(nsXPathNSResolver, mNode)
NS_IMPL_CYCLE_COLLECTING_ADDREF(nsXPathNSResolver)
NS_IMPL_CYCLE_COLLECTING_RELEASE(nsXPathNSResolver)
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(nsXPathNSResolver)
NS_INTERFACE_MAP_ENTRY(nsIDOMXPathNSResolver)
NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, nsIDOMXPathNSResolver)
NS_INTERFACE_MAP_ENTRY_CONTENT_CLASSINFO(XPathNSResolver)

Просмотреть файл

@ -43,6 +43,7 @@
#include "nsIDOMNode.h"
#include "nsIDOM3Node.h"
#include "nsCOMPtr.h"
#include "nsCycleCollectionParticipant.h"
/**
* A class for evaluating an XPath expression string
@ -53,7 +54,8 @@ public:
nsXPathNSResolver(nsIDOMNode* aNode);
// nsISupports interface
NS_DECL_ISUPPORTS
NS_DECL_CYCLE_COLLECTING_ISUPPORTS
NS_DECL_CYCLE_COLLECTION_CLASS(nsXPathNSResolver)
// nsIDOMXPathNSResolver interface
NS_DECL_NSIDOMXPATHNSRESOLVER