Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
libpgagroal: utils.c: fix UB in pgagroal_read_int32()
In pgagroal_read_int32, the byte[i] value is promoted to int32. According to the C spec, if you cannot represent the result in the result type, then that behavior is undefined (6.5.7). This issue is fixed by explicitly casting the bytes[i] values to uint32_t. Signed-off-by: Henrique de Carvalho <[email protected]>
- Loading branch information