Boost logo

Boost Users :

From: Martin Eigel (martin_eigel_at_[hidden])
Date: 2006-02-16 10:51:39


Thanks Joaquin, the patch seems to have solved it.
Martin.

Joaquín Mª López Muñoz wrote:
> Martin Eigel ha escrito:
>
>
>>Hi list,
>>
>>I am encountering a problem with MultiIndex which can
>>be resolved by disabling SAFE_MODE. As I actually do
>>not get the problem in the code attached below I'd
>>like to ask for an explanation. The marked line of
>>code (i.e. the second iterator assignment) seems to be
>>responsible for blocking MultiIndex's dtor in
>>
>>safe_mode.hpp:
>>void detach_all_iterators()
>>{
>> for(safe_iterator_base*
>>it=header.next;it;it=it->next)it->cont=0;
>>}
>>
>>Why is this and how can it correctly be avoided?
>>
>
>
> Hello Martin,
>
> Thank you very much for reporting the problem and providing a
> reproducible test case. This is a bug in the library, please try
> replacing
> the definition of detach_all_iterators in safe_mode.hpp with the
> following:
>
> void detach_all_iterators()
> {
> for(safe_iterator_base* it=header.next;it;it=it->next)it->cont=0;
> header.next=0;
> }
>
> This will eliminate the blocking you observe in safe mode, please report
>
> back. I'll be also committing this fix to the CVS asap.
>
> Thanks for using Boost.MultiIndex and for contributing to improve it,
>
> Joaquín M López Muñoz
> Telefónica, Investigación y Desarrollo


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