Files
Martin Vogel 29d05589dc
DCO / dco (push) Has been cancelled
fix(grammars): widen uint8_t loop counters in objectscript scanner (CodeQL)
CodeQL cpp/comparison-with-wider-type (4 high-severity alerts, #69-#72) flagged
two loops in the vendored ObjectScript scanner (objectscript_common.h, in both
the _routine and _udl grammar copies) where a uint8_t counter is compared
against an int length: the reverse_marker scan and the html_marker_buffer
reversal. Both lengths are hard-bounded by MARKER_BUFFER_MAX_LEN (30), so the
uint8_t counter can never wrap and the flagged infinite loop is unreachable in
practice — but widening the counters to int removes the pattern and clears the
gate. Provably behavior-neutral (int holds every uint8_t value; length <= 30).

Recorded as a local modification in the vendored grammar MANIFEST so it is
re-applied on the next re-vendor.

Signed-off-by: Martin Vogel <martin.vogel.tech@gmail.com>
2026-07-16 18:34:23 +02:00
..