Mailinglist Archive: libyui-devel (8 mails)

< Previous Next >
[libyui-devel] libyui-qt seg fault and doubt
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi I found this code:

// Ugly hack as a workaround of bug #121872 (Segfault at program exit
// if no Qt style defined):
//
// Qt does not seem to be designed for use in plugin libs. It loads some
// add-on libs dynamically with dlopen() and unloads them at program exit
// (QGPluginManager). Unfortunately, since they all depend on the Qt
master
// lib (libqt-mt) themselves, when they are unloading the last call to
// dlclose() for them causes the last reference to libqt-mt to vanish as
// well. Since libqt-mt is already in the process of destruction there is
// no more reference from the caller of libqt-mt, and the GLIBC decides
// that libqt-mt is not needed any more (zero references) and unmaps
// libqt-mt. When the static destructor of libqt-mt that triggered the
// cleanup in QGPluginManager returns, the code it is to return to is
// already unmapped, causing a segfault.
//
// Workaround: Keep one more reference to libqt-mt open - dlopen() it here
// and make sure there is no corresponding dlclose().

QString qt_lib_name = QString( QTLIBDIR "/libQtGui.so.%1" ).arg(
QT_VERSION >> 16 );;

But it does nothing, since QTLIBDIR and i suspect also QT_LOCALEDIR
are not set.

Then i've realized that libQtGui in qt5 is called libQt5Gui
but even forcing the right name and path it segfault anyway.

But maybe you that added this code know what means and
how to eventually fix.

Cheers,
Angelo
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.14 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iEYEARECAAYFAlMGgF0ACgkQqEs9DA4DquCTGQCfeRzDOJ93k6frPrxfA3NOkQJj
7WQAn2MYYNJ4y87GNEVm18Pi16QQ9PpN
=DuFU
-----END PGP SIGNATURE-----
--
To unsubscribe, e-mail: libyui-devel+unsubscribe@xxxxxxxxxxxx
To contact the owner, e-mail: libyui-devel+owner@xxxxxxxxxxxx

< Previous Next >
List Navigation
This Thread
  • No further messages