From 98738535dc859ede6fc8b7b9178a403ab62bd5f3 Mon Sep 17 00:00:00 2001 From: Daniel van Vugt Date: Wed, 30 Aug 2023 13:31:37 +0800 Subject: [PATCH] thread: Remove unused variable when HAVE_PROFILER is not defined MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This fixes a compiler warning: ``` meta-thread.c:297:16: warning: unused variable ‘context’ [-Wunused-variable] 297 | MetaContext *context = meta_backend_get_context (priv->backend); | ^~~~~~~ ``` Part-of: --- src/backends/native/meta-thread.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/backends/native/meta-thread.c b/src/backends/native/meta-thread.c index c99ad030b..08d01144d 100644 --- a/src/backends/native/meta-thread.c +++ b/src/backends/native/meta-thread.c @@ -292,11 +292,11 @@ thread_impl_func (gpointer user_data) { MetaThread *thread = META_THREAD (user_data); MetaThreadPrivate *priv = meta_thread_get_instance_private (thread); - MetaContext *context = meta_backend_get_context (priv->backend); MetaThreadImpl *impl = priv->impl; MetaThreadImplRunFlags run_flags = META_THREAD_IMPL_RUN_FLAG_NONE; GMainContext *thread_context = meta_thread_impl_get_main_context (impl); #ifdef HAVE_PROFILER + MetaContext *context = meta_backend_get_context (priv->backend); MetaProfiler *profiler = meta_context_get_profiler (context); #endif