Hi,
I have the following code :
QList<QObject*>Signals;
if( theApp->m_dcb.m_oSignalMap.count() > 0 )
{
Signals = theApp->m_dcb.m_oSignalMap.values( strId ) ;
if( Signals.size() > 0 )
{
CDADcb::CSignal* pSignal = (CDADcb::CSignal*)Signals.at(0);
// This signal belong to this CAN id, there can be many signals that do
{
// we need to do the conversion here - TODO
pSignal->m_strRawData = strData;
pSignal->m_nCount++;
}
}
}
QList<QObject*>Signals;
if( theApp->m_dcb.m_oSignalMap.count() > 0 )
{
Signals = theApp->m_dcb.m_oSignalMap.values( strId ) ;
if( Signals.size() > 0 )
{
CDADcb::CSignal* pSignal = (CDADcb::CSignal*)Signals.at(0);
// This signal belong to this CAN id, there can be many signals that do
{
// we need to do the conversion here - TODO
pSignal->m_strRawData = strData;
pSignal->m_nCount++;
}
}
}
To copy to clipboard, switch view to plain text mode
m_oSignalMap is a QMultiHash<QString, QObject*> of which CSignal objects are stored keyed on a string value. For some reason, this bit of code causes my application to crash at incoherent intervals, sometimes after a minute, sometimes after 5. The crash is in QHash.h when trying to find the key ( the key seems to be a bad ptr? ).
Sorry I can explain more, just seems so hit and miss...
Regards,
Steve
Bookmarks