[Boost-bugs] [Boost C++ Libraries] #2554: shared_ptr initialized with NULL returns use_count() == 1

Subject: [Boost-bugs] [Boost C++ Libraries] #2554: shared_ptr initialized with NULL returns use_count() == 1
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2008-12-01 05:36:54


#2554: shared_ptr initialized with NULL returns use_count() == 1
-----------------------+----------------------------------------------------
 Reporter: anonymous | Type: Bugs
   Status: new | Milestone: Boost 1.38.0
Component: None | Version: Boost 1.37.0
 Severity: Problem | Keywords:
-----------------------+----------------------------------------------------
 After creating shared_ptr with NULL initial value, it returns use_count()
 == 1:

 shared_ptr<int> p(NULL);
 cout << p.use_count() << endl;

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/2554>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:49:59 UTC