<div><div dir="auto"># HG changeset patch</div><div dir="auto"># User Yugo Horie <<a href="mailto:u5.horie@gmail.com" target="_blank">u5.horie@gmail.com</a>></div><div dir="auto"># Date 1677077775 -32400</div><div dir="auto"># Wed Feb 22 23:56:15 2023 +0900</div><div dir="auto"># Node ID 1a9487706c6af90baf2ed770db29f689c3850721</div><div dir="auto"># Parent cffaf3f2eec8fd33605c2a37814f5ffc30371989</div><div dir="auto">core: return error when the first byte is above 0xf5 in utf-8</div><div dir="auto"><br></div><div dir="auto">* see <a href="https://datatracker.ietf.org/doc/html/rfc3629#section-4" target="_blank">https://datatracker.ietf.org/doc/html/rfc3629#section-4</a></div><div dir="auto"><br></div><div dir="auto">diff -r cffaf3f2eec8 -r 1a9487706c6a src/core/ngx_string.c</div><div dir="auto">--- a/src/core/ngx_string.c Thu Feb 02 23:38:48 2023 +0300</div><div dir="auto">+++ b/src/core/ngx_string.c Wed Feb 22 23:56:15 2023 +0900</div><div dir="auto">@@ -1364,7 +1364,7 @@</div><div dir="auto"> </div><div dir="auto"> u = **p;</div><div dir="auto"> </div><div dir="auto">- if (u >= 0xf0) {</div><div dir="auto">+ if (u < 0xf5 && u >= 0xf0) {</div><div dir="auto"> </div><div dir="auto"> u &= 0x07;</div><div dir="auto"> valid = 0xffff;</div>
</div>