mirror of
https://git.mirrors.martin98.com/https://github.com/gulrak/filesystem
synced 2025-07-24 07:34:26 +08:00
refs #58, compile error on MinGW
This commit is contained in:
parent
26077f272e
commit
56827ea52d
4
.gitignore
vendored
4
.gitignore
vendored
@ -1,2 +1,4 @@
|
||||
/build*/
|
||||
/*build*/
|
||||
.vscode/
|
||||
.idea/
|
||||
*.swp
|
||||
|
@ -4225,7 +4225,11 @@ GHC_INLINE void resize_file(const path& p, uintmax_t size, std::error_code& ec)
|
||||
LARGE_INTEGER lisize;
|
||||
lisize.QuadPart = static_cast<LONGLONG>(size);
|
||||
if(lisize.QuadPart < 0) {
|
||||
#ifdef ERROR_FILE_TOO_LARGE
|
||||
ec = detail::make_system_error(ERROR_FILE_TOO_LARGE);
|
||||
#else
|
||||
ec = detail::make_system_error(223);
|
||||
#endif
|
||||
return;
|
||||
}
|
||||
std::shared_ptr<void> file(CreateFileW(detail::fromUtf8<std::wstring>(p.u8string()).c_str(), GENERIC_WRITE, 0, NULL, OPEN_EXISTING, 0, NULL), CloseHandle);
|
||||
|
Loading…
x
Reference in New Issue
Block a user