mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-20 22:41:10 +01:00
The draw encoder returns the empty blob for outlines without curves. Treating it as a clip sub-blob leaves a layer referring to the next payload or the end of the encoded data. Cache empty glyph and path clips separately and skip their consuming layers. Preserve the paint encoder's no-ink contract when only group operations remain, returning an empty blob with zero extents. Use fallible blob creation for gradient payloads so allocation failure cannot produce the same zero-length sub-blob references. Add an API regression using an ordinary font and paint callbacks, covering solid and gradient layers, empty paths, groups, and clip slot reuse. Validate the surviving layer's outline and band references. The regression fails on the original encoder; the full Meson suite passes (274 tests). Reported by Anthropic's OSS Scanner as ANT-2026-5Z1FLVCW. Assisted-by: OpenAI Codex