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
utils.hpp contains the following length check for is_compressed:
utils.hpp
is_compressed
return size > 2 && ...
However, it only uses the first two bytes. I would vote that length check should be return size >= 2 && ...
return size >= 2 && ...
This would allow me to do something like:
char gzipHeader[2]; file.read(gzipHeader, 2); file.seekg(0, ios::beg); // rewind if (gzip::is_compressed(gzipHeader, 2)) // do something...
The text was updated successfully, but these errors were encountered:
No branches or pull requests
utils.hpp
contains the following length check foris_compressed
:However, it only uses the first two bytes. I would vote that length check should be
return size >= 2 && ...
This would allow me to do something like:
The text was updated successfully, but these errors were encountered: