summaryrefslogtreecommitdiffstats
path: root/contrib/libc++/src/stdexcept.cpp
diff options
context:
space:
mode:
authortheraven <theraven@FreeBSD.org>2013-07-10 16:28:24 +0000
committertheraven <theraven@FreeBSD.org>2013-07-10 16:28:24 +0000
commit214e4f8fe625ad54aac3b215909e0b994a5768ec (patch)
treef757844d307e5ebbf92ab857f2376cceb7807147 /contrib/libc++/src/stdexcept.cpp
parentc660176671bf640bee3fd09dbfa32ad187a9b942 (diff)
downloadFreeBSD-src-214e4f8fe625ad54aac3b215909e0b994a5768ec.zip
FreeBSD-src-214e4f8fe625ad54aac3b215909e0b994a5768ec.tar.gz
Import new libcxxrt / libc++. This brings some bug fixes, including a potential race condition for static initialisers.
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