diff options
author | Vincent Richard <[email protected]> | 2008-07-11 21:07:32 +0000 |
---|---|---|
committer | Vincent Richard <[email protected]> | 2008-07-11 21:07:32 +0000 |
commit | 166f6206f42d1c1d6fa97d7e0315d99134252d9c (patch) | |
tree | 20c8ab9deede9720af8a2ededfd704b1685b231e /src | |
parent | Actually add the 'Final-Recipient' header (Zarafa). (diff) | |
download | vmime-166f6206f42d1c1d6fa97d7e0315d99134252d9c.tar.gz vmime-166f6206f42d1c1d6fa97d7e0315d99134252d9c.zip |
Fix for possible NULL return value for setlocale() (Zarafa).
Diffstat (limited to 'src')
-rw-r--r-- | src/platforms/posix/posixHandler.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/platforms/posix/posixHandler.cpp b/src/platforms/posix/posixHandler.cpp index e88f70f9..d1b782f7 100644 --- a/src/platforms/posix/posixHandler.cpp +++ b/src/platforms/posix/posixHandler.cpp @@ -113,9 +113,9 @@ const vmime::datetime posixHandler::getCurrentLocalTime() const const vmime::charset posixHandler::getLocaleCharset() const { - vmime::string prevLocale(::setlocale(LC_ALL, "")); + const char* prevLocale = ::setlocale(LC_ALL, ""); vmime::charset ch(::nl_langinfo(CODESET)); - ::setlocale(LC_ALL, prevLocale.c_str()); + ::setlocale(LC_ALL, prevLocale); return (ch); } |