$include_dir="/home/hyper-archives/boost-users/include"; include("$include_dir/msg-header.inc") ?>
Subject: [Boost-users] revisiting casting a boost::shared_ptr to void*
From: Chris Cleeland (chris.cleeland_at_[hidden])
Date: 2014-07-28 23:22:17
I'm resurrecting this topic:
because there is an unaddressed issue in it that I'm about to run into:
"... beware the pointee may be deleted if the last copy of the shared
pointer
goes out of scope, as the raw pointer won't have incremented the reference
count."
I cannot be the first person to run into this--a common issue when crossing
an API boundary. Has anyone come up with a good, safe solution wherein the
reference count gets properly incremented?
-- Chris Cleeland