KDE malloc SIGSEGV with PerlQt bindings + KDE themes
Karol Szwed
kszwed at cs.latrobe.edu.au
Tue Nov 19 14:40:42 GMT 2002
On Tuesday 19 November 2002 13:27, Germain Garand wrote:
> Hi,
> I'm investigating a segfault that happens when using some KDE themes (namely :
> riscos, marble, system, systemalt).
> It happens consistently when KDE's malloc attempts to free
> KStandardDirs::addKDEDefaults's QStringList.
>
> Would someone have a hint about what is going wrong ?
If the apps segfault on exit, it is most likely kthemestyle's linking to
kdecore that is causing the problem (KStaticDeleter again most
likely). You should not have any problems with all other style plugins
that do not link to kdecore.
If you grep for "__GLIBC__" in kthemestyle.cpp you'll see a workaround:
dlopen("kthemestyle.so",RTLD_LAZY);
This helps to ensure that apps don't crash on exit by preventing
the "dlclose" in Qt from having any effect on the plugin. This prevents
the plugin from being unloaded and avoids the segfault. This is probably
why valgrind is giving the all clear. Are you using libc on FreeBSD by
any chance in which case this workaround isn't enabled?
Please give more info on your platform and exactly how to reproduce
the crash if its not on exit.
-- Karol
More information about the kde-core-devel
mailing list