Merge pull request #1740 from ErikReider/gamemode-segfault-fix

This commit is contained in:
Alex 2022-10-20 13:09:50 +02:00 committed by GitHub
commit 1374b0fce4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -109,7 +109,7 @@ Gamemode::Gamemode(const std::string& id, const Json::Value& config)
} }
Gamemode::~Gamemode() { Gamemode::~Gamemode() {
if (gamemode_proxy) gamemode_proxy->unreference(); if (gamemode_proxy) gamemode_proxy.reset();
if (gamemodeWatcher_id > 0) { if (gamemodeWatcher_id > 0) {
Gio::DBus::unwatch_name(gamemodeWatcher_id); Gio::DBus::unwatch_name(gamemodeWatcher_id);
gamemodeWatcher_id = 0; gamemodeWatcher_id = 0;