diff options
author | Siteshwar Vashisht <siteshwar@gmail.com> | 2012-02-28 21:20:09 +0530 |
---|---|---|
committer | Siteshwar Vashisht <siteshwar@gmail.com> | 2012-02-28 21:20:09 +0530 |
commit | 392232246e9ea7539d331299a518ef63bab22483 (patch) | |
tree | 90b9f6e86d262ba479b7a2e0f0aa128b4e2846e5 /common.cpp | |
parent | cf54ad8242056ae6d686fa6455b24427f4411e18 (diff) |
Fixed compilation on Linux with some minor changes.
Diffstat (limited to 'common.cpp')
-rw-r--r-- | common.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -555,7 +555,13 @@ wchar_t *quote_end( const wchar_t *pos ) wcstring wsetlocale(int category, const wchar_t *locale) { - char *lang = locale?wcs2str( locale ):0; + char *lang = NULL; + if (locale && wcscmp(locale,L"")){ + lang = wcs2str( locale ); + } + { + lang = NULL; + } char * res = setlocale(category,lang); free( lang ); |