diff --git a/linux/CMakeLists.txt b/linux/CMakeLists.txt index 9f2184ae..af076aed 100644 --- a/linux/CMakeLists.txt +++ b/linux/CMakeLists.txt @@ -41,7 +41,7 @@ endif() # of modifying this function. function(APPLY_STANDARD_SETTINGS TARGET) target_compile_features(${TARGET} PUBLIC cxx_std_14) - target_compile_options(${TARGET} PRIVATE -Wall -Werror) + target_compile_options(${TARGET} PRIVATE -Wall) target_compile_options(${TARGET} PRIVATE "$<$>:-O3>") target_compile_definitions(${TARGET} PRIVATE "$<$>:NDEBUG>") endfunction() diff --git a/linux/runner/CMakeLists.txt b/linux/runner/CMakeLists.txt index 8487dbcc..c718b458 100644 --- a/linux/runner/CMakeLists.txt +++ b/linux/runner/CMakeLists.txt @@ -16,6 +16,7 @@ add_executable(${BINARY_NAME} # Apply the standard set of build settings. This can be removed for applications # that need different build settings. apply_standard_settings(${BINARY_NAME}) +target_compile_options(${BINARY_NAME} PRIVATE -Werror) # Add preprocessor definitions for the application ID. add_definitions(-DAPPLICATION_ID="${APPLICATION_ID}") diff --git a/linux/runner/desktop_platform_channel.cc b/linux/runner/desktop_platform_channel.cc index b26eee60..6a3b78b4 100644 --- a/linux/runner/desktop_platform_channel.cc +++ b/linux/runner/desktop_platform_channel.cc @@ -16,19 +16,7 @@ #include #include -namespace { - -constexpr char kChannelName[] = "plus.svc.xworkmate/desktop_platform"; -constexpr char kDesktopFileId[] = "plus.svc.xworkmate.desktop"; - -struct CommandResult { - bool ok = false; - int exit_status = -1; - std::string stdout_text; - std::string stderr_text; -}; - -struct DesktopPlatformChannel { +struct _DesktopPlatformChannel { MyApplication* application; GtkWindow* window; FlView* view; @@ -47,6 +35,18 @@ struct DesktopPlatformChannel { std::string status_message; }; +namespace { + +constexpr char kChannelName[] = "plus.svc.xworkmate/desktop_platform"; +constexpr char kDesktopFileId[] = "plus.svc.xworkmate.desktop"; + +struct CommandResult { + bool ok = false; + int exit_status = -1; + std::string stdout_text; + std::string stderr_text; +}; + std::string json_escape(const std::string& input) { std::ostringstream escaped; for (const char ch : input) {