g_thread_init is deprecated
Since glib 2.32 this function is just an empty body. Fix the warning and don't try to call it. There seems to be no way to disable threading in glib. Change-Id: Id30e606d341bd6ef871737275336f6c6b3b2559b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
This commit is contained in:
parent
29daf4ddf9
commit
3372b0faa7
@ -293,12 +293,14 @@ static GSourceFuncs postEventSourceFuncs = {
|
||||
QEventDispatcherGlibPrivate::QEventDispatcherGlibPrivate(GMainContext *context)
|
||||
: mainContext(context)
|
||||
{
|
||||
#if GLIB_MAJOR_VERSION == 2 && GLIB_MINOR_VERSION < 32
|
||||
if (qEnvironmentVariableIsEmpty("QT_NO_THREADED_GLIB")) {
|
||||
static QBasicMutex mutex;
|
||||
QMutexLocker locker(&mutex);
|
||||
if (!g_thread_supported())
|
||||
g_thread_init(NULL);
|
||||
}
|
||||
#endif
|
||||
|
||||
if (mainContext) {
|
||||
g_main_context_ref(mainContext);
|
||||
|
Loading…
x
Reference in New Issue
Block a user