diff --git a/gpx.cpp b/gpx.cpp index 27fa8ae..a731340 100644 --- a/gpx.cpp +++ b/gpx.cpp @@ -49,7 +49,7 @@ GPX::~GPX() { delete root; } -Caches GPX::get_user_caches(std::string uuid, int count) { +Caches GPX::get_user_caches(__attribute__((unused)) std::string uuid, __attribute__((unused)) int count) { Caches list; for (auto& el : items) { diff --git a/ocdb.cpp b/ocdb.cpp index 4b2f2bf..950f423 100644 --- a/ocdb.cpp +++ b/ocdb.cpp @@ -176,9 +176,9 @@ bool OCdb::update_cache(json j) { sql += i.first + ','; sql.pop_back(); sql += ") VALUES ('" + code + "',"; - for (auto& i : fields) + for (__attribute__((unused)) auto& i : fields) sql += "?,"; - for (auto& i : fields2) + for (__attribute__((unused)) auto& i : fields2) sql += "?,"; sql.pop_back(); sql += ") ON CONFLICT(code) DO UPDATE SET "; @@ -233,7 +233,7 @@ bool OCdb::update_log(json j) { sql += i.first + ','; sql.pop_back(); sql += ") VALUES ('" + uuid + "',"; - for (auto& i : fields) + for (__attribute__((unused)) auto& i : fields) sql += "?,"; sql.pop_back(); sql += ") ON CONFLICT(uuid) DO UPDATE SET "; @@ -311,7 +311,7 @@ Caches OCdb::get_user_caches_not_found(std::string uuid) { return cc; } -Caches OCdb::get_user_caches(std::string uuid, int count) { +Caches OCdb::get_user_caches(std::string uuid, __attribute__((unused)) int count) { int res; Caches cc; Cache c; diff --git a/okapi.cpp b/okapi.cpp index 41fa7b6..9aac9e5 100644 --- a/okapi.cpp +++ b/okapi.cpp @@ -17,7 +17,7 @@ static const std::string OKAPI_username = "services/users/by_username"; static const std::string OKAPI_changelog = "services/replicate/changelog"; // Callback for cURL easy interface used to save received output to std::string object -size_t Okapi::write_cb(char* ptr, size_t size, size_t nmemb, void* userdata) { +size_t Okapi::write_cb(char* ptr, __attribute__((unused)) size_t size, size_t nmemb, void* userdata) { std::string* str = reinterpret_cast(userdata); str->append(ptr, nmemb); return nmemb;