We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
In line 879 code,On 32-bite ,Get file size error,I modified part of the code 。
inline unsigned __int64 query_file_size(file_handle_type handle, std::error_code& error) { error.clear(); #ifdef _WIN32 // LARGE_INTEGER file_size; // if(::GetFileSizeEx(handle, &file_size) == 0) // { // error = detail::last_error(); // return 0; // } //return static_cast<int64_t>(file_size.QuadPart);
DWORD dwFileSizeHigh; __int64 qwFileSize = GetFileSize(handle, &dwFileSizeHigh); qwFileSize += (((_int64)dwFileSizeHigh) << 32); return qwFileSize;
#else // POSIX struct stat sbuf; if(::fstat(handle, &sbuf) == -1) { error = detail::last_error(); return 0; } return sbuf.st_size; #endif }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
In line 879 code,On 32-bite ,Get file size error,I modified part of the code 。
inline unsigned __int64 query_file_size(file_handle_type handle, std::error_code& error)
{
error.clear();
#ifdef _WIN32
// LARGE_INTEGER file_size;
// if(::GetFileSizeEx(handle, &file_size) == 0)
// {
// error = detail::last_error();
// return 0;
// }
//return static_cast<int64_t>(file_size.QuadPart);
#else // POSIX
struct stat sbuf;
if(::fstat(handle, &sbuf) == -1)
{
error = detail::last_error();
return 0;
}
return sbuf.st_size;
#endif
}
The text was updated successfully, but these errors were encountered: