From: wm4 Date: Sun, 9 Nov 2014 09:40:59 +0000 (+0100) Subject: Provide SIZE_MAX fallback X-Git-Tag: 0.12.1~40 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=dc054a1fdb1e9145e905612f296bbafd5ba7b530;p=libass Provide SIZE_MAX fallback SIZE_MAX is in C99, but not in C89. It is in , and is always a macro, so this fallback should be pretty portable and cause no issues. --- diff --git a/libass/ass_utils.h b/libass/ass_utils.h index 36826d3..6ae7328 100644 --- a/libass/ass_utils.h +++ b/libass/ass_utils.h @@ -32,6 +32,10 @@ #include "ass.h" +#ifndef SIZE_MAX +#define SIZE_MAX ((size_t)-1) +#endif + #define MSGL_FATAL 0 #define MSGL_ERR 1 #define MSGL_WARN 2