This commit is contained in:
2024-08-29 09:33:24 -05:00
parent 17ebd56ed4
commit 07ad8a55d3
8 changed files with 19 additions and 117 deletions

View File

@ -237,13 +237,7 @@ public:
file(file &&move_file) noexcept
: file_(std::move(move_file.file_)),
path_(std::move(move_file.path_)),
read_only_(move_file.read_only_)
#if defined(_WIN32)
,
mtx_(std::move(move_file.mtx_))
#endif // defined(_WIN32)
{
}
read_only_(move_file.read_only_) {}
~file() override { close(); }
@ -251,11 +245,6 @@ private:
file_t file_;
std::string path_;
bool read_only_{false};
#if defined(_WIN32)
mutable std::unique_ptr<std::recursive_mutex> mtx_{
new std::recursive_mutex(),
};
#endif // defined(_WIN32)
private:
std::atomic_uint32_t read_buffer_size{65536U};
@ -281,8 +270,6 @@ public:
return read_buffer_size;
}
[[nodiscard]] auto get_time(time_types type) const -> std::uint64_t override;
[[nodiscard]] auto is_read_only() const -> bool override {
return read_only_;
}
@ -322,9 +309,6 @@ public:
file_ = std::move(move_file.file_);
path_ = std::move(move_file.path_);
read_only_ = move_file.read_only_;
#if defined(_WIN32)
mtx_ = std::move(move_file.mtx_);
#endif // defined(_WIN32)
}
return *this;