Skip to content

Commit 317ad5d

Browse files
committed
See #204
It's too easy to accidentally call functions in `Vec` which may allocate, so rather than relying on the consumer to use `vec_push` instead of `Vec::push` and the like, make `TryVec` a thin wrapper around `Vec`, which will return `Result`s for all the operations which allocate and will use fallible allocation when the `mp4parse_fallible` feature is enabled. For now, as a proof of concept, only replace `Vec`s the newly-added AVIF code. If this works well, expanding to the rest of the code shouldn't be too much additional effort.
1 parent 63ca8c6 commit 317ad5d

File tree

2 files changed

+241
-70
lines changed

2 files changed

+241
-70
lines changed

0 commit comments

Comments
 (0)