diff options
author | 2015-02-06 23:21:58 +0000 | |
---|---|---|
committer | 2015-02-06 23:21:58 +0000 | |
commit | 4239b8225fa4f64aecb5a0fe486abd01f9e64ae2 (patch) | |
tree | bc2da4d9ac9052268d9b8328f3ed7de2e42e1e1f /lib/libc/stdio/getdelim.c | |
parent | list iwm(4) in pci(4); prodded by jmc (diff) | |
download | wireguard-openbsd-4239b8225fa4f64aecb5a0fe486abd01f9e64ae2.tar.xz wireguard-openbsd-4239b8225fa4f64aecb5a0fe486abd01f9e64ae2.zip |
SIZE_MAX is standard, we should be using it in preference to the
obsolete SIZE_T_MAX. OK miod@ beck@
Diffstat (limited to 'lib/libc/stdio/getdelim.c')
-rw-r--r-- | lib/libc/stdio/getdelim.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/libc/stdio/getdelim.c b/lib/libc/stdio/getdelim.c index 5e583cb5552..faf245ca6b1 100644 --- a/lib/libc/stdio/getdelim.c +++ b/lib/libc/stdio/getdelim.c @@ -1,4 +1,4 @@ -/* $OpenBSD: getdelim.c,v 1.2 2014/10/16 17:31:51 millert Exp $ */ +/* $OpenBSD: getdelim.c,v 1.3 2015/02/06 23:21:58 millert Exp $ */ /* $NetBSD: getdelim.c,v 1.13 2011/07/22 23:12:30 joerg Exp $ */ /* @@ -30,6 +30,7 @@ #include <errno.h> #include <limits.h> +#include <stdint.h> #include <stdio.h> #include <stdlib.h> #include <string.h> @@ -96,7 +97,7 @@ getdelim(char **__restrict buf, size_t *__restrict buflen, newlen |= newlen >> 4; newlen |= newlen >> 8; newlen |= newlen >> 16; -#if SIZE_T_MAX > 0xffffffffU +#if SIZE_MAX > 0xffffffffU newlen |= newlen >> 32; #endif newlen++; |