On Mon, 11 Oct 2021 18:16:28 GMT, Naoto Sato <na...@openjdk.org> wrote:
>> Wu Yan has updated the pull request incrementally with one additional commit >> since the last revision: >> >> replace realpath > > src/java.base/unix/native/libjava/TimeZone_md.c line 113: > >> 111: } >> 112: } >> 113: > > There are a few `*(right + 1)` references in the loops. Is there any > possibility that it would run over the buffer? It wouldn't run over the buffer. Here `end` points to `'\0'`. At line 94 and line 99, `right` is less than `end`, so `right + 1` is at most `end`. At line 103, if `right` equals `end`, `*right != '\0'` will be false and `!(*right == '/' && *(right + 1) == '/')` will not executed. ------------- PR: https://git.openjdk.java.net/jdk/pull/5327