gerddie / ginkgocadx

Advanced DICOM viewer
131 stars 38 forks source link

Program crashes when number of views is switched from 1x2 to 1x1 #14

Closed gerddie closed 8 years ago

gerddie commented 8 years ago

This is not a regression. valgrind log:

 Invalid read of size 8
 at 0x7588A7C: dcmtk::log4cplus::Logger::isEnabledFor(int) const (logger.cc:246)
    by 0x5F397D8: receiveTransportConnectionTCP(PRIVATE_NETWORKKEY**, DUL_BLOCKOPTIONS, int, DUL_ASSOCIATESERVICEPARAMETERS*, PRIVATE_ASSOCIATIONKEY**) (dul.cc:1594)
    by 0x5F3AE49: receiveTransportConnection (dul.cc:1498)
    by 0x5F3AE49: DUL_ReceiveAssociationRQ(void**, DUL_BLOCKOPTIONS, int, DUL_ASSOCIATESERVICEPARAMETERS*, void**, int) (dul.cc:616)
    by 0x5EF5AAC: ASC_receiveAssociation(T_ASC_Network*, T_ASC_Association**, long, void**, unsigned long*, bool, DUL_BLOCKOPTIONS, int) (assoc.cc:1764)
    by 0xBD0C11: GIL::DICOM::Service::acceptAssociation() (dicomservice.cpp:205)
    by 0xBD0703: GIL::DICOM::Service::Task() (dicomservice.cpp:176)
    by 0xDD58E6: GNC::GCS::ThreadAdaptorPrivate::Entry() (thread.cpp:121)
    by 0xBF72E69: wxThread::CallEntry() (thrimpl.cpp:356)
    by 0xBF799D2: wxThreadInternal::PthreadStart(wxThread*) (threadpsx.cpp:867)
    by 0x4E3F2CB: start_thread (pthread_create.c:333)
    by 0x24B9F04C: clone (clone.S:109)

Address 0x34730f70 is 0 bytes inside a block of size 120 free'd
    at 0x4C2A22B: operator delete(void*) (vg_replace_malloc.c:575)
    by 0x758859B: dcmtk::log4cplus::Logger::~Logger() (logger.cc:154)
    by 0x758770C: ~OFVector (ofvector.h:129)
    by 0x758770C: ~OFPair (ofutil.h:295)
    by 0x758770C: ~OFListLink (oflist.h:146)
    by 0x758770C: OFListLink<OFPair<OFString const, OFVector<dcmtk::log4cplus::Logger> >  >::~OFListLink() (oflist.h:146)
    by 0x732B181: OFListBase::base_erase(OFListLinkBase*) (oflist.cc:73)
    by 0x732B1AF: OFListBase::base_clear() (oflist.cc:100)
    by 0x732B1D6: OFListBase::~OFListBase() (oflist.cc:45)
    by 0x758753C: ~OFList (oflist.h:284)
    by 0x758753C: ~OFMap (ofmap.h:47)
    by 0x758753C: dcmtk::log4cplus::Hierarchy::~Hierarchy() (hierarchy.cc:83)
    by 0x75841A8: ~DefaultContext (globinit.cc:61)
    by 0x75841A8: dcmtk::log4cplus::(anonymous namespace)::destroy_default_context::~destroy_default_context() (globinit.cc:106)
    by 0x24AEFA16: __cxa_finalize (cxa_finalize.c:56)
    by 0x75723AA: ??? (in /usr/lib64/liboflog.so.3.6.1)
    by 0x400F366: _dl_fini (dl-fini.c:252)
    by 0x24AEF6B7: __run_exit_handlers (exit.c:82)

Block was alloc'd at
    at 0x4C2912F: operator new(unsigned long) (vg_replace_malloc.c:333)
    by 0x758894C: dcmtk::log4cplus::DefaultLoggerFactory::makeNewLoggerInstance(OFString const&, dcmtk::log4cplus::Hierarchy&) (logger.cc:39)
    by 0x75870A6: dcmtk::log4cplus::Hierarchy::getInstanceImpl(OFString const&, dcmtk::log4cplus::spi::LoggerFactory&) (hierarchy.cc:275)
    by 0x75851D8: dcmtk::log4cplus::Hierarchy::getInstance(OFString const&, dcmtk::log4cplus::spi::LoggerFactory&) (hierarchy.cc:172)
    by 0x7585121: dcmtk::log4cplus::Hierarchy::getInstance(OFString const&) (hierarchy.cc:163)
    by 0x75887CF: dcmtk::log4cplus::Logger::getInstance(OFString const&) (logger.cc:71)
    by 0x7572890: OFLog::getLogger(char const*) (oflog.cc:94)
    by 0x5EEF7D0: __static_initialization_and_destruction_0 (diutil.cc:116)
    by 0x5EEF7D0: _GLOBAL__sub_I_diutil.cc (diutil.cc:891)
    by 0x400ED69: call_init.part.0 (dl-init.c:72)
    by 0x400EECE: call_init (dl-init.c:126)
    by 0x400EECE: _dl_init (dl-init.c:120)
    by 0x4000BF9: ??? (in /lib64/ld-2.21.so)

Process terminating with default action of signal 11 (SIGSEGV)
  Bad permissions for mapped region at address 0x24896558
    at 0x24896558: ??? (in /usr/lib64/gcc/x86_64-pc-linux-gnu/5.3.0/libstdc++.so.6.0.21)
    by 0x5F397D8: receiveTransportConnectionTCP(PRIVATE_NETWORKKEY**, DUL_BLOCKOPTIONS, int, DUL_ASSOCIATESERVICEPARAMETERS*, PRIVATE_ASSOCIATIONKEY**) (dul.cc:1594)
    by 0x5F3AE49: receiveTransportConnection (dul.cc:1498)
    by 0x5F3AE49: DUL_ReceiveAssociationRQ(void**, DUL_BLOCKOPTIONS, int, DUL_ASSOCIATESERVICEPARAMETERS*, void**, int) (dul.cc:616)
    by 0x5EF5AAC: ASC_receiveAssociation(T_ASC_Network*, T_ASC_Association**, long, void**, unsigned long*, bool, DUL_BLOCKOPTIONS, int) (assoc.cc:1764)
    by 0xBD0C11: GIL::DICOM::Service::acceptAssociation() (dicomservice.cpp:205)
    by 0xBD0703: GIL::DICOM::Service::Task() (dicomservice.cpp:176)
    by 0xDD58E6: GNC::GCS::ThreadAdaptorPrivate::Entry() (thread.cpp:121)
    by 0xBF72E69: wxThread::CallEntry() (thrimpl.cpp:356)
    by 0xBF799D2: wxThreadInternal::PthreadStart(wxThread*) (threadpsx.cpp:867)
    by 0x4E3F2CB: start_thread (pthread_create.c:333)
    by 0x24B9F04C: clone (clone.S:109)
gerddie commented 8 years ago

Interestingly enough, switching from an NxN to 1x1 layout doesn't crash.