summaryrefslogtreecommitdiffstats
path: root/contrib/libc++/src/stdexcept.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/libc++/src/stdexcept.cpp')
-rw-r--r--contrib/libc++/src/stdexcept.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/libc++/src/stdexcept.cpp b/contrib/libc++/src/stdexcept.cpp
index 0c4e832..8d25f3e 100644
--- a/contrib/libc++/src/stdexcept.cpp
+++ b/contrib/libc++/src/stdexcept.cpp
@@ -61,7 +61,7 @@ __libcpp_nmstr::__libcpp_nmstr(const char* msg)
c[0] = c[1] = len;
str_ += offset;
count() = 0;
- std::strcpy(const_cast<char*>(c_str()), msg);
+ std::memcpy(const_cast<char*>(c_str()), msg, len + 1);
}
inline
OpenPOWER on IntegriCloud