mirror of
https://github.com/mhx/dwarfs.git
synced 2025-09-10 04:50:31 -04:00
fix(file_access): remove unnecessary special casing for windows
This commit is contained in:
parent
22af434200
commit
6ac70d64bf
@ -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 {
|
||||
|
Loading…
x
Reference in New Issue
Block a user