Fix the SIZE_T_MAX SSIZE_MAX defines.

This should not affect the underlying values, just the types used
by the defines.

This fixes any warnings where code does something like:

  printf("%zx", SIZE_T_MAX);

Change-Id: I4beb6d382f30261e4fe133a88fb503984911326d
This commit is contained in:
Christopher Ferris 2016-06-09 16:32:54 -07:00
parent 70d99a1053
commit 47fcffff60
1 changed files with 8 additions and 0 deletions

View File

@ -70,10 +70,18 @@
/* BSD compatibility definitions. */
#if __BSD_VISIBLE
#if defined(__LP64__)
#define SIZE_T_MAX ULONG_MAX
#else
#define SIZE_T_MAX UINT_MAX
#endif
#endif /* __BSD_VISIBLE */
#if defined(__LP64__)
#define SSIZE_MAX LONG_MAX
#else
#define SSIZE_MAX INT_MAX
#endif
#define MB_LEN_MAX 4