Skip to content

Commit

Permalink
Update documentation for plum_load_image to indicate the true cause…
Browse files Browse the repository at this point in the history
…s for `PLUM_ERR_IMAGE_TOO_LARGE`
  • Loading branch information
aaaaaa123456789 committed Jan 24, 2022
1 parent 34608d8 commit 60f912a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ Note: releases are listed from latest to oldest.
- Added detection for empty GIF files (erroring out with `PLUM_ERR_NO_DATA` instead of `PLUM_ERR_INVALID_FILE_FORMAT`)
- Improved PNG compression by fixing a lookback bug in the compressor and adjusting the lookback length
- Added and documented a restriction requiring `size_t` to be at least 32 bits wide
- Updated documentation for `plum_load_image` to indicate that a `PLUM_ERR_IMAGE_TOO_LARGE` error may also occur if
the image's overall dimensions are too large
- Some minor documentation updates and code cleanup

## Version 0.3 (10 January 2022)
Expand Down
2 changes: 1 addition & 1 deletion docs/functions.md
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ The error constants signal the following reasons for failure:
palette.
(This library doesn't support loading images with implicit palettes.)
- `PLUM_ERR_IMAGE_TOO_LARGE`: one of the image's dimensions (`width`, `height` or `frames`) doesn't fit in a 32-bit
unsigned integer.
unsigned integer, or the image is too large to be accessed through an array index.
- `PLUM_ERR_NO_DATA`: one of the image's dimensions (`width`, `height` or `frames`) is zero.
(This is possible for some image formats that allow image files to only contain ancillary data for further files to
use, such as palettes or decoder tables; this library doesn't use data from other files when decoding an image file,
Expand Down

0 comments on commit 60f912a

Please sign in to comment.