diff options
| author | gbezzuoli <guilhermebezzuoli@outlook.com> | 2026-11-22 18:46:57 -0300 |
|---|---|---|
| committer | gbezzuoli <guilhermebezzuoli@outlook.com> | 2026-11-22 18:46:57 -0300 |
| commit | a2f8aae55c22c3ba1d4cb8f8d39c5eb960543c1c (patch) | |
| tree | 452b899f605e2774850f9c0e4a354f8df12808a3 /runtime/test/tiny_game_exit_code_test.cpp | |
| parent | f847748cc76bd3777f9c070c4034eb2fc1c04e64 (diff) | |
rbf0_encode: --check fails on a refused resource; refuse attribute records the count does not cover (BUILD-1084)
Four findings by @HQasper on tools/rbf0_encode.py:
- `--check` exited 0 when resources were refused, so a round trip that verified nothing read as success.
It now exits 0 only when every resource is byte-identical, as rbf0_tree.py does for a resource that is
not ok.
- The element header count came from `attrs_declared` while every node of `attributes` was written, so an
attribute appended by hand encoded as the element's first content value: a different tree with status
ok. encode() now refuses more attribute records than the count (value), and an element short of its
count that has a value in its content, which would decode as an attribute (order). A parsed element
short of its count with no such value still round-trips exactly.
- `blob[:doc["size"]]` in resources() could not trim anything. The slice is gone and check() compares
the joined length with the recorded size; two carved streams of one name are refused instead of the
last one silently winning.
- docs/rbf0.md 9.6 lists the `value` refusals and says what `--check` exits with.
Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Diffstat (limited to 'runtime/test/tiny_game_exit_code_test.cpp')
0 files changed, 0 insertions, 0 deletions