Hello,
2009/7/6 Ted Ross <[email protected]>
> John Obaterspok wrote:
>
>> Hello,
>>
>> Any hints on while the below program always crashes?
>> (qpidc-0.5.752600 on i686)
>>
>> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> #include "qpid/console/ConsoleListener.h"
>> #include "qpid/console/SessionManager.h"
>> #include "qpid/sys/Time.h"
>>
>> void initQPID()
>> {
>> qpid::client::ConnectionSettings settings;
>> qpid::console::SessionManager sm;
>>
>> std::cout << "sm.addBroker:" << std::endl;
>> qpid::console::Broker* broker = sm.addBroker(settings);
>>
>> std::cout << "sm.delBroker" << std::endl;
>> sm.delBroker(broker);
>> }
>>
>> int main(int argc, char *argv[])
>> {
>> initQPID();
>> sleep(10);
>> }
>> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>>
>>
>>
> John,
>
> This crash is due to a bug that was fixed on the trunk in revision 782766 (
> http://svn.apache.org/viewvc?view=rev&revision=782766).
>
> -Ted
>
Thanks!
I've tried with latest svn before I sent the mail but it won't compile since
I use gcc 4.4:
qpid/sys/posix/SystemInfo.cpp: In function "void
qpid::sys::SystemInfo::getLocalIpAddresses(uint16_t,
std::vector<qpid::Address, std::allocator<qpid::Address> >&)":
qpid/sys/posix/SystemInfo.cpp:73: error: dereferencing pointer "sin" does
break strict-aliasing rules
I found some info here: https://bugzilla.redhat.com/show_bug.cgi?id=448743
but didn't know how to solve this.
/John