diff options
| author | Oz Linden <oz@lindenlab.com> | 2013-04-23 14:44:54 -0400 | 
|---|---|---|
| committer | Oz Linden <oz@lindenlab.com> | 2013-04-23 14:44:54 -0400 | 
| commit | aae4b025cb34fc05efa8319ee7ba6a6cef36734c (patch) | |
| tree | becf993c5e869c4f539c8e88089e51fed071afdd /indra/llcommon | |
| parent | 3bb708d70636188b91a6e8476a3b899441de0468 (diff) | |
| parent | bfb1ab134f7bcb0d2a8cfd73019d8999ae9a504a (diff) | |
merge changes for latest viewer-development
Diffstat (limited to 'indra/llcommon')
| -rwxr-xr-x | indra/llcommon/llfile.cpp | 21 | 
1 files changed, 15 insertions, 6 deletions
| diff --git a/indra/llcommon/llfile.cpp b/indra/llcommon/llfile.cpp index bc615ed39e..864b6e6975 100755 --- a/indra/llcommon/llfile.cpp +++ b/indra/llcommon/llfile.cpp @@ -853,7 +853,8 @@ llifstream::llifstream(const std::string& _Filename,  #if LL_WINDOWS  	std::istream(&_M_filebuf)  { -	if (_M_filebuf.open(_Filename.c_str(), _Mode | ios_base::in) == 0) +	llutf16string wideName = utf8str_to_utf16str( _Filename ); +	if (_M_filebuf.open(wideName.c_str(), _Mode | ios_base::in) == 0)  	{  		_Myios::setstate(ios_base::failbit);  	} @@ -872,7 +873,8 @@ llifstream::llifstream(const char* _Filename,  #if LL_WINDOWS  	std::istream(&_M_filebuf)  { -	if (_M_filebuf.open(_Filename, _Mode | ios_base::in) == 0) +	llutf16string wideName = utf8str_to_utf16str( _Filename ); +	if (_M_filebuf.open(wideName.c_str(), _Mode | ios_base::in) == 0)  	{  		_Myios::setstate(ios_base::failbit);  	} @@ -917,8 +919,10 @@ bool llifstream::is_open() const  void llifstream::open(const char* _Filename, ios_base::openmode _Mode)  {	// open a C stream with specified mode -	if (_M_filebuf.open(_Filename, _Mode | ios_base::in) == 0) +  #if LL_WINDOWS +	llutf16string wideName = utf8str_to_utf16str( _Filename ); +	if (_M_filebuf.open( wideName.c_str(), _Mode | ios_base::in) == 0)  	{  		_Myios::setstate(ios_base::failbit);  	} @@ -927,6 +931,7 @@ void llifstream::open(const char* _Filename, ios_base::openmode _Mode)  		_Myios::clear();  	}  #else +	if (_M_filebuf.open(_Filename, _Mode | ios_base::in) == 0)  	{  		this->setstate(ios_base::failbit);  	} @@ -969,7 +974,8 @@ llofstream::llofstream(const std::string& _Filename,  #if LL_WINDOWS  	std::ostream(&_M_filebuf)  { -	if (_M_filebuf.open(_Filename.c_str(), _Mode | ios_base::out) == 0) +	llutf16string wideName = utf8str_to_utf16str( _Filename ); +	if (_M_filebuf.open( wideName.c_str(), _Mode | ios_base::out) == 0)  	{  		_Myios::setstate(ios_base::failbit);  	} @@ -988,7 +994,8 @@ llofstream::llofstream(const char* _Filename,  #if LL_WINDOWS  	std::ostream(&_M_filebuf)  { -	if (_M_filebuf.open(_Filename, _Mode | ios_base::out) == 0) +	llutf16string wideName = utf8str_to_utf16str( _Filename ); +	if (_M_filebuf.open( wideName.c_str(), _Mode | ios_base::out) == 0)  	{  		_Myios::setstate(ios_base::failbit);  	} @@ -1032,8 +1039,9 @@ bool llofstream::is_open() const  void llofstream::open(const char* _Filename, ios_base::openmode _Mode)  {	// open a C stream with specified mode -	if (_M_filebuf.open(_Filename, _Mode | ios_base::out) == 0)  #if LL_WINDOWS +	llutf16string wideName = utf8str_to_utf16str( _Filename ); +	if (_M_filebuf.open( wideName.c_str(), _Mode | ios_base::out) == 0)  	{  		_Myios::setstate(ios_base::failbit);  	} @@ -1042,6 +1050,7 @@ void llofstream::open(const char* _Filename, ios_base::openmode _Mode)  		_Myios::clear();  	}  #else +	if (_M_filebuf.open(_Filename, _Mode | ios_base::out) == 0)  	{  		this->setstate(ios_base::failbit);  	} | 
