From aa26153b6cb8353c1cd64667ec55ab5186fa1036 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Tue, 21 Mar 2023 20:04:58 +0000 Subject: [PATCH] patch 9.0.1420: build failure because SIZE_MAX is not defined Problem: Build failure because SIZE_MAX is not defined. Solution: Define SIZE_MAX when missing. (John Marriott) --- src/version.c | 2 ++ src/xdiff/xmacros.h | 6 +++++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/version.c b/src/version.c index 379980a4f8..32c39be5d5 100644 --- a/src/version.c +++ b/src/version.c @@ -695,6 +695,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 1420, /**/ 1419, /**/ diff --git a/src/xdiff/xmacros.h b/src/xdiff/xmacros.h index 8487bb396f..f58cf08e73 100644 --- a/src/xdiff/xmacros.h +++ b/src/xdiff/xmacros.h @@ -24,7 +24,11 @@ #define XMACROS_H - +#ifdef __hpux +# ifndef SIZE_MAX +# define SIZE_MAX ((size_t)(-1)) +# endif +#endif #define XDL_MIN(a, b) ((a) < (b) ? (a): (b)) #define XDL_MAX(a, b) ((a) > (b) ? (a): (b))