[
https://issues.apache.org/jira/browse/THRIFT-6358?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jens Geyer resolved THRIFT-6358.
--------------------------------
Fix Version/s: 0.26.0
Resolution: Fixed
> OCaml skip reads one element too many for maps, sets and lists
> --------------------------------------------------------------
>
> Key: THRIFT-6358
> URL: https://issues.apache.org/jira/browse/THRIFT-6358
> Project: Thrift
> Issue Type: Bug
> Components: OCaml - Library
> Reporter: Jens Geyer
> Priority: Minor
> Fix For: 0.26.0
>
>
> The map, set and list cases of {{skip}} in {{Thrift.ml}} looped over
> {{0..s}}, which is one iteration more than the declared count {{s}}, so
> skipping a container read one element past its end.
> Fixed on master by
> [1519d955a|https://github.com/apache/thrift/commit/1519d955a6623ba78ff0a043b1a60444a3644e06]:
> the loops skip exactly the declared number of elements.
> Reported by Sylwester Lachiewicz.
> _Drafted with AI assistance (Claude Opus 5); reviewed and posted by Jens
> Geyer._
--
This message was sent by Atlassian Jira
(v8.20.10#820010)