mirror of
https://github.com/glest/glest-source.git
synced 2025-09-27 07:59:00 +02:00
- more updates to handle unicode (most of the focus was getting tools working in windows using non ascii file paths)
This commit is contained in:
@@ -22,6 +22,7 @@
|
||||
#include "types.h"
|
||||
#include "properties.h"
|
||||
#include "platform_common.h"
|
||||
#include "platform_util.h"
|
||||
#include "leak_dumper.h"
|
||||
|
||||
|
||||
@@ -106,8 +107,12 @@ XmlNode *XmlIo::load(const string &path, std::map<string,string> mapTagReplaceme
|
||||
config->setParameter(XMLUni::fgDOMValidate, true);
|
||||
#endif
|
||||
XERCES_CPP_NAMESPACE_QUALIFIER DOMDocument *document= parser->parseURI(path.c_str());
|
||||
|
||||
if(document==NULL){
|
||||
#ifdef WIN32
|
||||
if(document == NULL) {
|
||||
document= parser->parseURI(utf8_decode(path).c_str());
|
||||
}
|
||||
#endif
|
||||
if(document == NULL) {
|
||||
throw runtime_error("Can not parse URL: " + path);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user