diff options
author | Jacek Antonelli | 2008-08-15 23:45:42 -0500 |
---|---|---|
committer | Jacek Antonelli | 2008-08-15 23:45:42 -0500 |
commit | ce28e056c20bf2723f565bbf464b87781ec248a2 (patch) | |
tree | ef7b0501c4de4b631a916305cbc2a5fdc125e52d /linden/indra/llcommon/llstring.cpp | |
parent | Second Life viewer sources 1.19.1.4b (diff) | |
download | meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.zip meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.tar.gz meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.tar.bz2 meta-impy-ce28e056c20bf2723f565bbf464b87781ec248a2.tar.xz |
Second Life viewer sources 1.20.2
Diffstat (limited to 'linden/indra/llcommon/llstring.cpp')
-rw-r--r-- | linden/indra/llcommon/llstring.cpp | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/linden/indra/llcommon/llstring.cpp b/linden/indra/llcommon/llstring.cpp index 73c80e7..a1f19ad 100644 --- a/linden/indra/llcommon/llstring.cpp +++ b/linden/indra/llcommon/llstring.cpp | |||
@@ -804,16 +804,19 @@ std::string utf8str_removeCRLF(const std::string& utf8str) | |||
804 | 804 | ||
805 | #if LL_WINDOWS | 805 | #if LL_WINDOWS |
806 | // documentation moved to header. Phoenix 2007-11-27 | 806 | // documentation moved to header. Phoenix 2007-11-27 |
807 | int safe_snprintf(char *str, size_t size, const char *format, ...) | 807 | namespace snprintf_hack |
808 | { | 808 | { |
809 | va_list args; | 809 | int snprintf(char *str, size_t size, const char *format, ...) |
810 | va_start(args, format); | 810 | { |
811 | 811 | va_list args; | |
812 | int num_written = _vsnprintf(str, size, format, args); /* Flawfinder: ignore */ | 812 | va_start(args, format); |
813 | va_end(args); | 813 | |
814 | 814 | int num_written = _vsnprintf(str, size, format, args); /* Flawfinder: ignore */ | |
815 | str[size-1] = '\0'; // always null terminate | 815 | va_end(args); |
816 | return num_written; | 816 | |
817 | str[size-1] = '\0'; // always null terminate | ||
818 | return num_written; | ||
819 | } | ||
817 | } | 820 | } |
818 | 821 | ||
819 | std::string ll_convert_wide_to_string(const wchar_t* in) | 822 | std::string ll_convert_wide_to_string(const wchar_t* in) |