From 5096c0459f5a8dde8ec25099b163aca3ed8e81aa Mon Sep 17 00:00:00 2001 From: "akkana%netscape.com" Date: Wed, 20 Oct 1999 20:20:38 +0000 Subject: [PATCH] 15777: Don't declare the same function-static symbol twice in the same file, because some versions of gcc can't deal with it. r=mcafee --- content/base/src/nsDocumentEncoder.cpp | 9 +++------ layout/base/src/nsDocumentEncoder.cpp | 9 +++------ 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/content/base/src/nsDocumentEncoder.cpp b/content/base/src/nsDocumentEncoder.cpp index cc8d77831786..be265f19beed 100644 --- a/content/base/src/nsDocumentEncoder.cpp +++ b/content/base/src/nsDocumentEncoder.cpp @@ -38,6 +38,9 @@ static NS_DEFINE_CID(kComponentManagerCID, NS_COMPONENTMANAGER_CID); static NS_DEFINE_CID(kCTextEncoderCID, NS_TEXT_ENCODER_CID); +static NS_DEFINE_IID(kCParserIID, NS_IPARSER_IID); +static NS_DEFINE_IID(kCParserCID, NS_PARSER_IID); + class nsTextEncoder : public nsIDocumentEncoder { public: @@ -175,9 +178,6 @@ nsTextEncoder::EncodeToString(nsString& aOutputString) nsIParser* parser; - static NS_DEFINE_IID(kCParserIID, NS_IPARSER_IID); - static NS_DEFINE_IID(kCParserCID, NS_PARSER_IID); - rv = nsComponentManager::CreateInstance(kCParserCID, nsnull, kCParserIID, @@ -236,9 +236,6 @@ nsTextEncoder::EncodeToStream(nsIOutputStream* aStream) nsIParser* parser; - static NS_DEFINE_IID(kCParserIID, NS_IPARSER_IID); - static NS_DEFINE_IID(kCParserCID, NS_PARSER_IID); - rv = nsComponentManager::CreateInstance(kCParserCID, nsnull, kCParserIID, diff --git a/layout/base/src/nsDocumentEncoder.cpp b/layout/base/src/nsDocumentEncoder.cpp index cc8d77831786..be265f19beed 100644 --- a/layout/base/src/nsDocumentEncoder.cpp +++ b/layout/base/src/nsDocumentEncoder.cpp @@ -38,6 +38,9 @@ static NS_DEFINE_CID(kComponentManagerCID, NS_COMPONENTMANAGER_CID); static NS_DEFINE_CID(kCTextEncoderCID, NS_TEXT_ENCODER_CID); +static NS_DEFINE_IID(kCParserIID, NS_IPARSER_IID); +static NS_DEFINE_IID(kCParserCID, NS_PARSER_IID); + class nsTextEncoder : public nsIDocumentEncoder { public: @@ -175,9 +178,6 @@ nsTextEncoder::EncodeToString(nsString& aOutputString) nsIParser* parser; - static NS_DEFINE_IID(kCParserIID, NS_IPARSER_IID); - static NS_DEFINE_IID(kCParserCID, NS_PARSER_IID); - rv = nsComponentManager::CreateInstance(kCParserCID, nsnull, kCParserIID, @@ -236,9 +236,6 @@ nsTextEncoder::EncodeToStream(nsIOutputStream* aStream) nsIParser* parser; - static NS_DEFINE_IID(kCParserIID, NS_IPARSER_IID); - static NS_DEFINE_IID(kCParserCID, NS_PARSER_IID); - rv = nsComponentManager::CreateInstance(kCParserCID, nsnull, kCParserIID,