aboutsummaryrefslogtreecommitdiff
path: root/src/common/windows
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/windows')
-rw-r--r--src/common/windows/string_utils-inl.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/common/windows/string_utils-inl.h b/src/common/windows/string_utils-inl.h
index db18124d..6f650812 100644
--- a/src/common/windows/string_utils-inl.h
+++ b/src/common/windows/string_utils-inl.h
@@ -56,6 +56,10 @@
// _snwprintf when using older CRTs.
#if _MSC_VER < 1400 // MSVC 2005/8
#define swprintf _snwprintf
+#else
+// For MSVC8 and newer, swprintf_s is the recommended method. Conveniently,
+// it takes the same argument list as swprintf.
+#define swprintf swprintf_s
#endif // MSC_VER < 1400
namespace google_breakpad {