better to use boost::shared_ptr