diff options
author | NRK <nrk@disroot.org> | 2022-05-11 21:20:55 +0600 |
---|---|---|
committer | Michael Forney <mforney@mforney.org> | 2022-05-11 11:15:56 -0700 |
commit | ef3b6b33eba80b82ae3da1d8e322b531bfc99902 (patch) | |
tree | 55ce92c8dd1fc5286d14dd5f07ed20ea67a23359 /stmt.c | |
parent | fb00ba697821de4fb3d8d0dd44edfa5f4727d067 (diff) |
expr: fix erroneous comparison
as long as `size_t`'s conversion rank is >= `int` this check would work
out fine.
but in case size_t happens to be less than int (which I believe is valid
under the C standard) then comparison will take place in `signed int`
and the operand `-1` will not get implicitly converted to SIZE_MAX.
explicitly cast it to size_t to avoid such issues.
Diffstat (limited to 'stmt.c')
0 files changed, 0 insertions, 0 deletions