Initialize _owned in the copy constructor as well.

[SVN r43739]
This commit is contained in:
Peter Dimov
2008-03-20 22:10:52 +00:00
parent 1c2d780f9e
commit 5b17f88f0e

View File

@@ -45,6 +45,7 @@ template<class T> class enable_shared_from_this
mutable shared_ptr<_internal_element_type> _internal_shared_this;
mutable weak_ptr<_internal_element_type> _internal_weak_this;
mutable bool _owned;
protected:
enable_shared_from_this():
@@ -52,7 +53,8 @@ protected:
{
}
enable_shared_from_this(enable_shared_from_this const &)
enable_shared_from_this(enable_shared_from_this const &):
_owned(false)
{
}