[Interest] Segfault: qHash(QString const&) in libQtCore.so.4
Thiago Macieira
thiago.macieira at intel.com
Wed Oct 2 18:37:36 CEST 2013
On quarta-feira, 2 de outubro de 2013 17:26:21, Peter Smith wrote:
> Hi all,
>
> I'm having problems with QGIS seg faulting, and it looks like the
> problem is in QT (hence posting on this list):
No, it isn't.
> (gdb) bt
> #0 0x00007ffff59445a3 in qHash(QString const&) () from
> /usr/lib64/libQtCore.so.4
This function is trying to hash the QString you passed it. Hashing only
happens on hash or set keys. So find where the akey parameter was passed from:
> #1 0x000000000044c2a3 in QHash<QString, QHashDummyValue>::findNode
> (this=0x87eac0, akey=..., ahp=0x0) at /usr/include/QtCore/qhash.h:875
> #2 0x0000000000477b92 in QHash<QString, QHashDummyValue>::contains
> (this=0x87eac0, akey=...) at /usr/include/QtCore/qhash.h:867
> #3 0x0000000000475797 in QSet<QString>::contains (this=0x87eac0,
> value=...) at /usr/include/QtCore/qset.h:86
> #4 0x000000000045cc7e in QgsProjectParser::mapLayerFromStyle
> (this=0x87e9e0, lName=..., styleName=..., useCache=true) at
> /root/qgis/qgis-2.0.1/src/mapserver/qgsprojectparser.cpp:1365
At this point in the code, you made a call to contains(). The string you
passed is not valid. You probably have dangling pointers or other problems if
you managed to get an invalid QString.
You may want to try running your application in valgrind.
--
Thiago Macieira - thiago.macieira (AT) intel.com
Software Architect - Intel Open Source Technology Center
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 190 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20131002/cf059b5c/attachment.sig>
More information about the Interest
mailing list