ifdef expat until more testing can be done

git-svn-id: svn://10.0.0.236/trunk@22704 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
rickg%netscape.com
1999-03-03 08:55:23 +00:00
parent 26bb7f0161
commit 6bea38145b
2 changed files with 16 additions and 0 deletions

View File

@@ -36,7 +36,10 @@
#include "nsIHTMLContentSink.h"
#include "nsHTMLTokenizer.h"
#include "nsXMLTokenizer.h"
#ifdef EXPAT
#include "nsExpatTokenizer.h"
#endif
#include "prenv.h" //this is here for debug reasons...
#include "prtypes.h" //this is here for debug reasons...
@@ -329,6 +332,8 @@ nsITokenRecycler* CWellFormedDTD::GetTokenRecycler(void){
nsITokenizer* CWellFormedDTD::GetTokenizer(void) {
if(!mTokenizer) {
PRBool theExpatState=PR_FALSE;
#ifdef EXPAT
char* theEnvString = PR_GetEnv("EXPAT");
if(theEnvString){
if(('1'==theEnvString[0]) || ('Y'==toupper(theEnvString[0]))) {
@@ -338,6 +343,9 @@ nsITokenizer* CWellFormedDTD::GetTokenizer(void) {
if(theExpatState)
mTokenizer=(nsHTMLTokenizer*)new nsExpatTokenizer();
else mTokenizer=(nsHTMLTokenizer*)new nsXMLTokenizer();
#else
mTokenizer=(nsHTMLTokenizer*)new nsXMLTokenizer();
#endif
}
return mTokenizer;
}