mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-07 01:43:41 +02:00
GRand: Make sure to g_thread_init_glib()
The last commit should g_thread_init_glib() before attempting to use GOnce.
This commit is contained in:
@@ -133,6 +133,8 @@ get_random_version (void)
|
||||
static gsize initialized = FALSE;
|
||||
static guint random_version;
|
||||
|
||||
g_thread_init_glib ();
|
||||
|
||||
if (g_once_init_enter (&initialized))
|
||||
{
|
||||
const gchar *version_string = g_getenv ("G_RANDOM_VERSION");
|
||||
|
Reference in New Issue
Block a user