Boost logo

Boost Users :

From: gzahl_at_[hidden]
Date: 2007-02-15 07:21:52


Hi,

> Hello Manuel,
>> Hi,
>>
>> Im defining a class with a multi_index_container as base.
>> When i construct a instance of this class, and the
>> multi_index_container is called, the program crashes. It even
>> crashes, when i dont use it as a base class.
> [...]
>> This compiles just fine, but if i run the code i get the
>> following backtrace after a Sigmentation Abort. It happens,
>> when the queue::queue() is called. Someone a idee whats it
>> about? Im new to boost::multi_index, so maybe i misunderstud
>> something? Thank you
>
> Well, what you're doing is AFAICS correct, so you shouldn't
> be getting this crash. You haven't provided a complete
> test program showing producing the crash, so I wrote one
> myself after what you've shown and tried it locally, no
> problems here. Could you please try the attached jung.cpp
> file? Does it crash also? If it doesn't then there's more
> to your program than you have described, maybe you can
> send compilable program showing the issue. If jung.cpp
> crashes, then could you please provide the following info?

The Testprogramm jung.cpp does not crash on my machines (im testing on a ubuntu 6.10 and a debian 3.1 system, both working with g++ 4.0.2)
I will try to get a example which reproduces my error, but in the meantime i was thinking about the libc stuff. Maybe this is the real problem thing? i changed to 4.0.2 from a 3.x version just some weeks ago, so maybe here is the problem, because some lib im using is not compiled with 4.0.2? is there a way i can get the compiler version a library was compiled with?

>
> 1. What system are you running this on?
> 2. The stacktrace mentions a failed assertion in libc.so. Can
> you see the source code that's causing the assertion? Maybe
> it sheds some light.

Im not sure about, where to see this sourcecode?

 scoped_lock(lightweight_mutex & m): m_(m.m_)
        {
            pthread_mutex_lock(&m_);
        }

these are the lines alst mentioned in the backtrace "/usr/local/include/boost/detail/lwm_pthreads.hpp:72" from #5. But this is not what you meant, right?

> 3. Can you try the attached lock.cpp file? Crash/no crash?
>

I didnt tried, because example worked fine.

> Looking forward to your response,

Thanks for help so far. I hope we can fix it soon. Ill go on, cut some working code out, which reproduces the error.

> Joaquín M López Muñoz
> Telefónica, Investigación y Desarrollo

Manuel Jung

Viel oder wenig? Schnell oder langsam? Unbegrenzt surfen + telefonieren
ohne Zeit- und Volumenbegrenzung? DAS TOP ANGEBOT JETZT bei Arcor: günstig
und schnell mit DSL - das All-Inclusive-Paket für clevere Doppel-Sparer,
nur 44,85 € inkl. DSL- und ISDN-Grundgebühr!
http://www.arcor.de/rd/emf-dsl-2


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