From 80a36e7c39b9036e2c2fa20f7915a835bdd21272 Mon Sep 17 00:00:00 2001 From: WolverinDEV Date: Thu, 30 Jan 2020 13:37:14 +0100 Subject: [PATCH] Fixed music crash --- CMakeLists.txt | 3 ++- music | 2 +- server/src/client/command_handler/misc.cpp | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 6422900..40cb316 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -63,6 +63,8 @@ find_package(spdlog REQUIRED) find_package(Jemalloc REQUIRED) find_package(Protobuf REQUIRED) +include_directories(${StringVariable_INCLUDE_DIR}) +add_subdirectory(music/) # LibEvent fucks up the CMAKE_FIND_LIBRARY_SUFFIXES variable macro(find_event static) @@ -88,7 +90,6 @@ include_directories(${LIBEVENT_INCLUDE_DIRS}) include_directories(${StringVariable_INCLUDE_DIR}) add_definitions(-DINET -DINET6) -add_subdirectory(music/) add_subdirectory(shared/) add_subdirectory(server/) add_subdirectory(license/) diff --git a/music b/music index a5df205..77ebfe6 160000 --- a/music +++ b/music @@ -1 +1 @@ -Subproject commit a5df20561ec66c6b8f80c96c4fadf03152959059 +Subproject commit 77ebfe653cc5565d59e927cf7a542a5737e8fdf4 diff --git a/server/src/client/command_handler/misc.cpp b/server/src/client/command_handler/misc.cpp index 795389e..57e7518 100644 --- a/server/src/client/command_handler/misc.cpp +++ b/server/src/client/command_handler/misc.cpp @@ -830,7 +830,7 @@ command_result ConnectedClient::handleCommandBanClient(Command &cmd) { return command_result{error::client_unknown}; } - if(!permission::v2::permission_granted(this->server->calculate_permission(permission::i_client_needed_ban_power, target_dbid, ClientType::CLIENT_TEAMSPEAK, 0)), this->calculate_permission(permission::i_client_ban_power, 0)) + if(!permission::v2::permission_granted(this->server->calculate_permission(permission::i_client_needed_ban_power, target_dbid, ClientType::CLIENT_TEAMSPEAK, 0), this->calculate_permission(permission::i_client_ban_power, 0))) return command_result{permission::i_client_ban_power}; if (permission::v2::permission_granted(1, this->server->calculate_permission(permission::b_client_ignore_bans, target_dbid, ClientType::CLIENT_TEAMSPEAK, 0)))