From 56c00789dcb3d7533533f798b0b2d5acb4b04052 Mon Sep 17 00:00:00 2001 From: Landry Breuil Date: Tue, 5 Nov 2024 18:17:44 +0000 Subject: [PATCH] Bug 1926030: fix build on !ENABLE_DBUS after bug 1917548 r=stransky Differential Revision: https://phabricator.services.mozilla.com/D227683 --- widget/gtk/WakeLockListener.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/widget/gtk/WakeLockListener.cpp b/widget/gtk/WakeLockListener.cpp index 9a2376d46ab9..787969addfab 100644 --- a/widget/gtk/WakeLockListener.cpp +++ b/widget/gtk/WakeLockListener.cpp @@ -820,10 +820,12 @@ nsresult WakeLockTopic::ProcessNextRequest() { void WakeLockTopic::Shutdown() { WAKE_LOCK_LOG("WakeLockTopic::Shutdown() state %s", GetInhibitStateName(mState)); +#if defined(MOZ_ENABLE_DBUS) if (mCancellable) { g_cancellable_cancel(mCancellable); mCancellable = nullptr; } +#endif } bool WakeLockTopic::IsWakeLockTypeAvailable(int aWakeLockType) {