diff options
author | Larry Hajali <larryhaja[at]gmail[dot]com> | 2010-05-12 23:29:22 +0200 |
---|---|---|
committer | David Somero <xgizzmo@slackbuilds.org> | 2010-05-12 23:29:22 +0200 |
commit | 52ded40386444b9ddf135da7b2581c570eecc240 (patch) | |
tree | 130898019e560c95a5aedf40cabc6fd0387ed791 /games/glest/glest-xerces-c.patch | |
parent | 55655a60b15221ab7bcf5d185ee603a3a682cd1d (diff) | |
download | slackbuilds-52ded40386444b9ddf135da7b2581c570eecc240.tar.gz |
games/glest: Added to 12.2 repository
Diffstat (limited to 'games/glest/glest-xerces-c.patch')
-rw-r--r-- | games/glest/glest-xerces-c.patch | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/games/glest/glest-xerces-c.patch b/games/glest/glest-xerces-c.patch new file mode 100644 index 0000000000..f7582060b3 --- /dev/null +++ b/games/glest/glest-xerces-c.patch @@ -0,0 +1,41 @@ +--- source/shared_lib/sources/xml/xml_parser.cpp.old 2008-02-16 16:01:28.000000000 +0300 ++++ source/shared_lib/sources/xml/xml_parser.cpp 2009-03-19 18:28:08.000000000 +0300 +@@ -87,10 +87,17 @@ + + try{ + ErrorHandler errorHandler; ++#if XERCES_VERSION_MAJOR < 3 + DOMBuilder *parser= (static_cast<DOMImplementationLS*>(implementation))->createDOMBuilder(DOMImplementationLS::MODE_SYNCHRONOUS, 0); + parser->setErrorHandler(&errorHandler); + parser->setFeature(XMLUni::fgXercesSchemaFullChecking, true); + parser->setFeature(XMLUni::fgDOMValidation, true); ++#else ++ DOMLSParser *parser = (static_cast<DOMImplementationLS*>(implementation))->createLSParser(DOMImplementationLS::MODE_SYNCHRONOUS, 0); ++ DOMConfiguration *config = parser->getDomConfig(); ++ config->setParameter(XMLUni::fgXercesSchemaFullChecking, true); ++ config->setParameter(XMLUni::fgDOMValidate, true); ++#endif + DOMDocument *document= parser->parseURI(path.c_str()); + + if(document==NULL){ +@@ -119,9 +126,20 @@ + } + + LocalFileFormatTarget file(path.c_str()); ++#if XERCES_VERSION_MAJOR < 3 + DOMWriter* writer = implementation->createDOMWriter(); + writer->setFeature(XMLUni::fgDOMWRTFormatPrettyPrint, true); + writer->writeNode(&file, *document); ++#else ++ DOMLSSerializer *serializer = implementation->createLSSerializer(); ++ DOMLSOutput* output=implementation->createLSOutput(); ++ DOMConfiguration* config=serializer->getDomConfig(); ++ config->setParameter(XMLUni::fgDOMWRTFormatPrettyPrint,true); ++ output->setByteStream(&file); ++ serializer->write(document,output); ++ output->release(); ++ serializer->release(); ++#endif + document->release(); + } + catch(const DOMException &e){ |