diff options
| author | ruki <[email protected]> | 2025-12-11 23:46:31 +0800 |
|---|---|---|
| committer | ruki <[email protected]> | 2025-12-12 09:00:45 +0800 |
| commit | 334605bbe1bbe5b6b00b920b1228ef26b6288939 (patch) | |
| tree | 66536b1eee39ae02469a9d4aaf4049a1bd1a00be /core/src/xmake/binutils/mslib | |
| parent | 37bdf54bca0239804274185501064c44256c876e (diff) | |
fix compile error
Diffstat (limited to 'core/src/xmake/binutils/mslib')
| -rw-r--r-- | core/src/xmake/binutils/mslib/extractlib.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/core/src/xmake/binutils/mslib/extractlib.c b/core/src/xmake/binutils/mslib/extractlib.c index 5dec97f3e..8912070ae 100644 --- a/core/src/xmake/binutils/mslib/extractlib.c +++ b/core/src/xmake/binutils/mslib/extractlib.c @@ -124,8 +124,8 @@ tb_bool_t xm_binutils_mslib_extract(tb_stream_ref_t istream, tb_char_t const *ou is_longname_table = tb_true; } else if (tb_isdigit(header.name[1])) { // offset into long name table (/123) - tb_long_t offset = xm_binutils_mslib_parse_decimal(header.name + 1, 15); - if (offset >= 0 && offset < longnames_size) { + tb_int64_t offset = xm_binutils_mslib_parse_decimal(header.name + 1, 15); + if (offset >= 0 && (tb_size_t)offset < longnames_size) { // copy from longnames // names in longnames are null-terminated tb_strlcpy(member_name, longnames + offset, sizeof(member_name)); |
