Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/desktop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCamila <hello@camila.codes>2022-08-10 15:32:14 +0300
committerGitHub <noreply@github.com>2022-08-10 15:32:14 +0300
commitddcb8344377684dc6cbe3d612f5d22336b0586c6 (patch)
tree2696d32a8e19756a7d51f81b222102f3d32da217
parent55fda4e2757fcf505210c22bcb10340fefc8f017 (diff)
parent5c7b6e7af44e04dadcaeb3cf9ef5626f9fa725b1 (diff)
Merge pull request #4804 from nextcloud/feature/enableMoreWarningsAlsoForGcc
Feature/enable more warnings also for gcc
-rw-r--r--cmake/modules/Warnings.cmake2
-rw-r--r--src/libsync/propagateremotedeleteencryptedrootfolder.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/cmake/modules/Warnings.cmake b/cmake/modules/Warnings.cmake
index ccac090e5..371e7bcd0 100644
--- a/cmake/modules/Warnings.cmake
+++ b/cmake/modules/Warnings.cmake
@@ -19,7 +19,7 @@ if (CMAKE_CXX_COMPILER_ID MATCHES "GNU|Clang")
execute_process(COMMAND ${CMAKE_C_COMPILER} -dumpversion
OUTPUT_VARIABLE GCC_VERSION)
if(GCC_VERSION VERSION_GREATER 4.8 OR GCC_VERSION VERSION_EQUAL 4.8)
- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wpedantic")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wpedantic")
else(GCC_VERSION VERSION_GREATER 4.8 OR GCC_VERSION VERSION_EQUAL 4.8)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pedantic")
endif(GCC_VERSION VERSION_GREATER 4.8 OR GCC_VERSION VERSION_EQUAL 4.8)
diff --git a/src/libsync/propagateremotedeleteencryptedrootfolder.cpp b/src/libsync/propagateremotedeleteencryptedrootfolder.cpp
index 6dfe3c1d3..add0c00da 100644
--- a/src/libsync/propagateremotedeleteencryptedrootfolder.cpp
+++ b/src/libsync/propagateremotedeleteencryptedrootfolder.cpp
@@ -153,7 +153,7 @@ void PropagateRemoteDeleteEncryptedRootFolder::slotDeleteNestedRemoteItemFinishe
if (_nestedItems.size() == 0) {
// we wait for all _nestedItems' DeleteJobs to finish, and then - fail if any of those jobs has failed
if (networkError() != QNetworkReply::NetworkError::NoError || _item->_httpErrorCode != 0) {
- const int errorCode = networkError() != QNetworkReply::NetworkError::NoError ? networkError() : _item->_httpErrorCode;
+ const auto errorCode = (networkError() != QNetworkReply::NetworkError::NoError ? static_cast<int>(networkError()) : _item->_httpErrorCode);
qCCritical(PROPAGATE_REMOVE_ENCRYPTED_ROOTFOLDER) << "Delete of nested items finished with error" << errorCode << ". Failing the entire sequence.";
taskFailed();
return;