From 32dfc11c23ec89a994ec92a98e2f9a5c0fbd93db Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Thu, 17 Oct 2013 19:27:02 +0200 Subject: Main: use ThreadId instead of GThread* --- src/UpdateGlue.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/UpdateGlue.cxx') diff --git a/src/UpdateGlue.cxx b/src/UpdateGlue.cxx index 50af6271d..e55668c55 100644 --- a/src/UpdateGlue.cxx +++ b/src/UpdateGlue.cxx @@ -33,6 +33,7 @@ #include "Main.hxx" #include "Instance.hxx" #include "system/FatalError.hxx" +#include "thread/Id.hxx" #include @@ -92,7 +93,7 @@ static void * update_task(void *_path) static void spawn_update_task(const char *path) { - assert(g_thread_self() == main_task); + assert(main_thread.IsInside()); progress = UPDATE_PROGRESS_RUNNING; modified = false; @@ -115,7 +116,7 @@ spawn_update_task(const char *path) unsigned update_enqueue(const char *path, bool _discard) { - assert(g_thread_self() == main_task); + assert(main_thread.IsInside()); if (!db_is_simple() || !mapper_has_music_directory()) return 0; -- cgit v1.2.3