[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#482286: Outlining the interesting bits in the traces



I'm not very fluent in debugging cpp; however this might help a quick sorting 
out (otherwise see original bug report for full traces):

1) in http://tuttu.info/~feth/valgrind_designer-qt4.log :

==27607== Process terminating with default action of signal 11 (SIGSEGV)
==27607==  Access not within mapped region at address 0xE496CB38
==27607==    at 0xD82C69C: KCharSelectData::sectionContents(int) 
(kcharselectdata.cpp:174)
==27607==    by 0xD824A14: 
KCharSelect::KCharSelectPrivate::_k_sectionSelected(int) 
(kcharselect.cpp:601)
==27607==    by 0xD826AD8: KCharSelect::KCharSelect(QWidget*, 
QFlags<KCharSelect::Control>) (kcharselect.cpp:373)
==27607==    by 0xDDBB844: KCharSelectPlugin::createWidget(QWidget*) 
(kdewidgets.cpp:305)

2) ./kdeui/widgets/kcharselectdata.cpp around line 174

155 QList<int> KCharSelectData::sectionContents(int section)
156 {
157     if(!openDataFile()) {
158         return QList<int>();
159     }
160
161     const char* data = dataFile->constData();
162     const quint32 offsetBegin = * (quint32*) (data+28);
163     const quint32 offsetEnd = * (quint32*) (data+32);
164
165     int max = ((offsetEnd - offsetBegin) / 4) - 1;
166
167     QList<int> res;
168
169     if(section > max)
170         return res;
171
172     for(int i = 0; i <= max; i++) {
173         const quint16 currSection = * (quint16*) (data + offsetBegin + 
i*4);
174         if(currSection == section) {
175             res.append( * (quint16*) (data + offsetBegin + i*4 + 2) );
176         }
177     }
178
179     return res;
180 }


-- 
Feth Arezki



Reply to: