Commit b691d312 authored by Max Kellermann's avatar Max Kellermann

IOThread: pass GError to FatalError()

Fixes build failure on GLib < 2.32.
parent f68e36f8
...@@ -22,6 +22,7 @@ ...@@ -22,6 +22,7 @@
#include "thread/Mutex.hxx" #include "thread/Mutex.hxx"
#include "thread/Cond.hxx" #include "thread/Cond.hxx"
#include "event/Loop.hxx" #include "event/Loop.hxx"
#include "system/FatalError.hxx"
#include <glib.h> #include <glib.h>
...@@ -76,9 +77,10 @@ io_thread_start() ...@@ -76,9 +77,10 @@ io_thread_start()
#if GLIB_CHECK_VERSION(2,32,0) #if GLIB_CHECK_VERSION(2,32,0)
io.thread = g_thread_new("io", io_thread_func, nullptr); io.thread = g_thread_new("io", io_thread_func, nullptr);
#else #else
io.thread = g_thread_create(io_thread_func, NULL, true, error_r); GError *error = nullptr;
io.thread = g_thread_create(io_thread_func, NULL, true, &error);
if (io.thread == NULL) if (io.thread == NULL)
FatalError(); FatalError(error);
#endif #endif
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment