Skip to content
New issue

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

Compress/Decompress routines should return Errnos #39

Open
asomers opened this issue Apr 20, 2018 · 0 comments
Open

Compress/Decompress routines should return Errnos #39

asomers opened this issue Apr 20, 2018 · 0 comments

Comments

@asomers
Copy link

asomers commented Apr 20, 2018

When an error happens, the API leaves the user wondering why. I suggest that blosc_compress, blosc2_compress_ctx, blosc_decompress, blosc2_decompress_ctx, blosc_getitem, and blosc2_getitem_ctx should all return -1 on error and set errno. Alternatively, Blosc could define its own error codes with negative values.

This would be especially useful for the decompress routines, which can return an error either because the destination buffer is too small, the data is corrupted, or the decompression library is unavailable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant