Summary: | std::make_shared does not perform zero initialization | ||
---|---|---|---|
Product: | Base System | Reporter: | Dimitry Andric <dim> |
Component: | misc | Assignee: | freebsd-bugs (Nobody) <bugs> |
Status: | Closed FIXED | ||
Severity: | Affects Some People | ||
Priority: | --- | ||
Version: | 10.3-STABLE | ||
Hardware: | Any | ||
OS: | Any | ||
URL: | https://bugs.llvm.org/show_bug.cgi?id=32002 |
Description
Dimitry Andric
![]() ![]() A commit references this bug: Author: dim Date: Sat Feb 18 14:44:14 UTC 2017 New revision: 313916 URL: https://svnweb.freebsd.org/changeset/base/313916 Log: Pull in r242377 from upstream libc++ trunk (by Marshall Clow): Make sure that __libcpp_compressed_pair_imp default-constructs its' members, rather than value-initializing them. Fixes PR#24137 This ensures std::make_shared<>'s default constructor properly initializes to zero. Direct commit to stable/9 and stable/10, since stable/11 and head already have a newer version of libc++, including this fix. Reported by: martin.beran@kernun.cz PR: 217200 Changes: stable/10/contrib/libc++/include/memory stable/9/contrib/libc++/include/memory |