Boost logo

Boost Users :

From: Timmo Stange (ts_at_[hidden])
Date: 2007-02-17 15:34:40


Frank Mori Hess wrote:

> connect also checks use_count() after locking the slot list mutex. It
> calls nolock_force_unique_connection_list(), which creates a (expensive, I
> know) new copy of the slot list if it is already in use.

Hm, I found that function, but I don't see it getting called from
connect().

>> Another thing: The original signal is safe against deletion from
>> a slot invocation context. That's why it uses pimpl-Idiom.
>
> Hmm, I didn't consider that case. Since I've already got the pimpl there
> for signal tracking, I suppose I just need to create a local copy of the
> shared_ptr pimpl to prevent it from destructing in mid-invocation.

Yes.

Regards

Timmo Stange


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