From 3d6e1e559abfcbc1d6d1e3d3f80d8a6adb409472 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Tue, 29 Sep 2015 13:44:49 -0700 Subject: [PATCH] client: fix set_client_priority() --- client/client_state.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/client/client_state.cpp b/client/client_state.cpp index f64776f65e..89c8b887ea 100644 --- a/client/client_state.cpp +++ b/client/client_state.cpp @@ -379,7 +379,10 @@ bool CLIENT_STATE::is_new_client() { #ifdef _WIN32 typedef DWORD (WINAPI *SPC)(HANDLE, DWORD); +#endif + static void set_client_priority() { +#ifdef _WIN32 SPC spc = (SPC) GetProcAddress(GetModuleHandle(_T("kernel32.dll")), "SetPriorityClass"); if (!spc) return; if (spc(GetCurrentProcess(), PROCESS_MODE_BACKGROUND_BEGIN)) {