RFR: 8251505: Use of types in compiler shared code should be consistent.

Evgeny Astigeevich duke at openjdk.java.net
Tue Feb 1 12:15:11 UTC 2022


On Tue, 1 Feb 2022 03:35:13 GMT, Yi-Fan Tsai <duke at openjdk.java.net> wrote:

> 8251505: Use of types in compiler shared code should be consistent.

Changes requested by eastig at github.com (no known OpenJDK username).

src/hotspot/share/utilities/elfFile.cpp line 94:

> 92: }
> 93: 
> 94: bool FileReader::set_position(int64_t offset) {

You introduce a bug here.
`fseek` declaration:

int fseek ( FILE * stream, long int offset, int origin );


`fseek` will read only 32 bits of `offset` if `sizeof(long)==32`.

-------------

PR: https://git.openjdk.java.net/jdk/pull/7294


More information about the hotspot-dev mailing list