From 4911928412dfe2b1d3e9966dcd101790d02046de Mon Sep 17 00:00:00 2001 From: Kleis Auke Wolthuizen Date: Tue, 24 Mar 2020 11:14:47 +0100 Subject: [PATCH] Only call g_get_language_names when GLib < 2.48.1 The thread-safety problem was fixed in GLib 2.48.1. See: https://bugzilla.gnome.org/show_bug.cgi?id=748474 --- libvips/iofuncs/init.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libvips/iofuncs/init.c b/libvips/iofuncs/init.c index 9b5b7532..6f3cc51f 100644 --- a/libvips/iofuncs/init.c +++ b/libvips/iofuncs/init.c @@ -391,7 +391,9 @@ vips_init( const char *argv0 ) * we have to make sure we do this single-threaded. See: * https://github.com/openslide/openslide/issues/161 */ +#if !GLIB_CHECK_VERSION( 2, 48, 1 ) (void) g_get_language_names(); +#endif if( !vips__global_lock ) vips__global_lock = vips_g_mutex_new();