Skip to content
Snippets Groups Projects
Commit 21de3391 authored by Jakub Jelinek's avatar Jakub Jelinek
Browse files

hwint: Fix up preprocessor conditions for GCC_PRISZ/fmt_size_t

Using unsigned long long int for fmt_size_t and "ll" for GCC_PRISZ
as broke the gengtype on i686-linux before the libiberty fix is certainly
unexpected.  size_t is there unsigned int, so expected fmt_size_t is
unsigned int (or some other 32-bit type).

The problem was that I was comparing SIZE_MAX against signed maxima,
but SIZE_MAX is unsigned maximum.

2024-02-13  Jakub Jelinek  <jakub@redhat.com>

	* hwint.h (GCC_PRISZ, fmt_size_t): Fix preprocessor conditions,
	instead of comparing SIZE_MAX against INT_MAX and LONG_MAX compare
	it against UINT_MAX and ULONG_MAX.
parent 6caec7d9
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment