PR libstdc++/81891 fix double-free in hashtable constructor
commit21b932faac20b613fcb482c4bd996fb9acf0c1da
authorredi <redi@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 18 Aug 2017 17:46:57 +0000 (18 17:46 +0000)
committerredi <redi@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 18 Aug 2017 17:46:57 +0000 (18 17:46 +0000)
treedfbe1a715b12079e6ed0e120937397676b8ccd3a
parentf04d3651be0a327589ab632f1fe23e94c39d88f6
PR libstdc++/81891 fix double-free in hashtable constructor

PR libstdc++/81891
* include/bits/hashtable.h (_Hashtable(_InputIterator, _InputIterator,
size_type, const _H1&, const _H2&, const _Hash&, const _Equal&,
const _ExtractKey&, const allocator_type&)): Let destructor do clean
up if an exception is thrown.
* testsuite/23_containers/unordered_map/cons/81891.cc: New.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@251185 138bc75d-0d04-0410-961f-82ee72b054a4
libstdc++-v3/ChangeLog
libstdc++-v3/include/bits/hashtable.h
libstdc++-v3/testsuite/23_containers/unordered_map/cons/81891.cc [new file with mode: 0644]