diff options
author | Jeremy Messenger <mezz@FreeBSD.org> | 2007-04-02 16:57:48 +0000 |
---|---|---|
committer | Jeremy Messenger <mezz@FreeBSD.org> | 2007-04-02 16:57:48 +0000 |
commit | 551fded38f17dae9a22c4621b1eee090e543099b (patch) | |
tree | df00dbb24d7d42f2eaa7fc70c4e51ed69f31aabe /net-p2p/linuxdcpp/files | |
parent | Update to 1.14 (diff) |
Catch up with the latest CVS, fix the charset/locale stuff. Bump the
PORTREVISION.
Bug tracker: http://tinyurl.com/2hrvgn (berlios.de)
Obtained from: LinuxDC++ CVS
Diffstat (limited to 'net-p2p/linuxdcpp/files')
-rw-r--r-- | net-p2p/linuxdcpp/files/patch-client_Text.cpp | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/net-p2p/linuxdcpp/files/patch-client_Text.cpp b/net-p2p/linuxdcpp/files/patch-client_Text.cpp new file mode 100644 index 000000000000..959bd01da306 --- /dev/null +++ b/net-p2p/linuxdcpp/files/patch-client_Text.cpp @@ -0,0 +1,32 @@ +=================================================================== +RCS file: /cvsroot/linuxdcpp/linuxdcpp/client/Text.cpp,v +retrieving revision 1.15 +retrieving revision 1.16 +diff -u -r1.15 -r1.16 +--- client/Text.cpp 2007/03/24 18:33:17 1.15 ++++ client/Text.cpp 2007/03/28 00:03:12 1.16 +@@ -25,6 +25,7 @@ + #ifndef _WIN32 + #include <errno.h> + #include <iconv.h> ++#include <langinfo.h> + + #ifndef ICONV_CONST + #define ICONV_CONST +@@ -38,12 +39,16 @@ + void Text::initialize() { + setlocale(LC_ALL, ""); + ++#ifdef _WIN32 + char *ctype = setlocale(LC_CTYPE, NULL); + if(ctype) { + systemCharset = string(ctype); + } else { + dcdebug("Unable to determine the program's locale"); + } ++#else ++ systemCharset = string(nl_langinfo(CODESET)); ++#endif + } + + int Text::utf8ToWc(const char* str, wchar_t& c) { |