Boost logo

Boost Users :

Subject: Re: [Boost-users] shared_ptr question
From: Eric J. Holtman (eric_at_[hidden])
Date: 2010-05-18 10:52:52


On 5/18/2010 9:38 AM, Michael Jackson wrote:
>
> if (rx)
>
> is only testing if the wrapper is valid, NOT the actual pointer itself that
> is being wrapped. What you really want is:
>
> If (rx.get() != NULL)
>
>

No, you don't need that.

http://www.boost.org/doc/libs/1_43_0/libs/smart_ptr/shared_ptr.htm#conversions


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net