Address compiler warnings #10
Some checks failed
BlockStorage/repertory_osx/pipeline/head This commit looks good
BlockStorage/repertory_linux_builds/pipeline/head There was a failure building this commit

This commit is contained in:
2023-10-30 13:31:52 -05:00
parent e7413fb741
commit 639d14452b
10 changed files with 1129 additions and 631 deletions

View File

@@ -82,7 +82,6 @@
#include <optional>
#include <random>
#include <sstream>
#include <sstream>
#include <string>
#include <string_view>
#include <thread>
@@ -90,6 +89,14 @@
#include <unordered_map>
#include <vector>
#include <sodium.h>
template <typename data_type>
[[nodiscard]] constexpr auto repertory_rand() -> data_type {
data_type ret{};
randombytes_buf(&ret, sizeof(ret));
return ret;
}
#include <boost/archive/text_iarchive.hpp>
#include <boost/archive/text_oarchive.hpp>
#include <boost/asio.hpp>
@@ -116,7 +123,6 @@
#endif
#include <pugixml.hpp>
#include <sodium.h>
#define CPPHTTPLIB_TCP_NODELAY true
#define CPPHTTPLIB_OPENSSL_SUPPORT
@@ -136,12 +142,12 @@ using json = nlohmann::json;
#define REPERTORY_API_INVALID_HANDLE static_cast<std::uint64_t>(-1)
using native_handle = HANDLE;
#else
#define REPERTORY_INVALID_HANDLE -1
#define REPERTORY_INVALID_HANDLE (-1)
#define REPERTORY_API_INVALID_HANDLE REPERTORY_INVALID_HANDLE
using native_handle = int;
#endif
#define NANOS_PER_SECOND 1000000000L
constexpr const auto NANOS_PER_SECOND = 1000000000L;
#ifdef _WIN32
#ifdef CreateDirectory
@@ -339,6 +345,7 @@ using WCHAR = wchar_t;
#define STATUS_OBJECT_NAME_NOT_FOUND std::int32_t(0xC0000034L)
#define STATUS_OBJECT_PATH_INVALID std::int32_t(0xC0000039L)
#define STATUS_UNEXPECTED_IO_ERROR std::int32_t(0xC00000E9L)
#define CONVERT_STATUS_NOT_IMPLEMENTED(e) \
((std::int32_t(e) == STATUS_NOT_IMPLEMENTED) ? -ENOTSUP : e)