Commit 8af9bf1d authored by vitaut's avatar vitaut

Use FMT_SECURE_SCL instead of _SECURE_SCL

parent de3cea7f
...@@ -48,11 +48,13 @@ ...@@ -48,11 +48,13 @@
# include <sstream> # include <sstream>
#endif #endif
#ifndef _SECURE_SCL #ifdef _SECURE_SCL
# define _SECURE_SCL 0 # define FMT_SECURE_SCL _SECURE_SCL
#else
# define FMT_SECURE_SCL 0
#endif #endif
#if _SECURE_SCL #if FMT_SECURE_SCL
# include <iterator> # include <iterator>
#endif #endif
...@@ -394,7 +396,7 @@ namespace internal { ...@@ -394,7 +396,7 @@ namespace internal {
// to avoid dynamic memory allocation. // to avoid dynamic memory allocation.
enum { INLINE_BUFFER_SIZE = 500 }; enum { INLINE_BUFFER_SIZE = 500 };
#if _SECURE_SCL #if FMT_SECURE_SCL
// Use checked iterator to avoid warnings on MSVC. // Use checked iterator to avoid warnings on MSVC.
template <typename T> template <typename T>
inline stdext::checked_array_iterator<T*> make_ptr(T *ptr, std::size_t size) { inline stdext::checked_array_iterator<T*> make_ptr(T *ptr, std::size_t size) {
...@@ -625,7 +627,7 @@ inline int isnotanumber(long double x) { ...@@ -625,7 +627,7 @@ inline int isnotanumber(long double x) {
template <typename Char> template <typename Char>
class BasicCharTraits { class BasicCharTraits {
public: public:
#if _SECURE_SCL #if FMT_SECURE_SCL
typedef stdext::checked_array_iterator<Char*> CharPtr; typedef stdext::checked_array_iterator<Char*> CharPtr;
#else #else
typedef Char *CharPtr; typedef Char *CharPtr;
...@@ -1910,7 +1912,7 @@ class BasicWriter { ...@@ -1910,7 +1912,7 @@ class BasicWriter {
typedef typename internal::CharTraits<Char>::CharPtr CharPtr; typedef typename internal::CharTraits<Char>::CharPtr CharPtr;
#if _SECURE_SCL #if FMT_SECURE_SCL
// Returns pointer value. // Returns pointer value.
static Char *get(CharPtr p) { return p.base(); } static Char *get(CharPtr p) { return p.base(); }
#else #else
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment