From: Doug Gregor (dgregor_at_[hidden])
Date: 2004-09-23 17:42:23


On Sep 5, 2004, at 5:51 PM, Dave Deakins wrote:
> So my question is this: When a slot object (not a signal object) is
> destroyed, what tells the trackable objects that are used by the slot
> that
> they can release their connection to this slot?

Uh-oh.

> Can someone please confirm if this behavior happens on other systems
> or if
> maybe there is some pecularity with my system/compiler?

Confirmed. There is clearly a bug here. Thanks for pointing this out
and especially for distilling it down to a simple test case.

> If this situation
> is not peculiar to my system, should there be a:
>
> watch_bound_objects.set_controlling();
>
> statement at the very end of the slot_base::create_connection()
> procedure
> (after the safe_connection.release() statement) in slot.cpp?

I don't think that's the right solution, because watch_bound_objects
gets copied around a bit, and would then disconnect too early. I'm
revisiting this code now to try to isolate the bug.

        Doug