fix(file_access): remove unnecessary special casing for windows

This commit is contained in:
Marcus Holland-Moritz 2023-12-31 16:17:20 +01:00
parent 22af434200
commit 6ac70d64bf

View File

@ -25,10 +25,6 @@
#include <fmt/format.h>
#ifdef _WIN32
#include <folly/portability/Windows.h>
#endif
#include "dwarfs/file_access.h"
#include "dwarfs/file_access_generic.h"
#include "dwarfs/util.h"
@ -38,11 +34,7 @@ namespace dwarfs {
namespace {
void assign_error_code(std::error_code& ec) {
#ifdef _WIN32
ec.assign(::GetLastError(), std::system_category());
#else
ec.assign(errno, std::generic_category());
#endif
}
class file_input_stream : public input_stream {