From 4b61daa6023ceeb7d2eba3a1a28cf42415200d99 Mon Sep 17 00:00:00 2001 From: Lephenixnoir Date: Sat, 13 Aug 2022 00:01:30 +0200 Subject: [PATCH] stdio: use non-zero values for SEEK_* libstdc++ uses 0, SEEK_CUR, SEEK_END in an internal enumeration. By having SEEK_CUR=0 we would have a duplicate case. --- include/stdio.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/stdio.h b/include/stdio.h index a136da9..205c33a 100644 --- a/include/stdio.h +++ b/include/stdio.h @@ -125,9 +125,9 @@ typedef size_t fpos_t; #define L_tmpnam FILENAME_MAX /* Seeking positions. */ -#define SEEK_CUR 0 -#define SEEK_END 1 -#define SEEK_SET 2 +#define SEEK_CUR 1 +#define SEEK_END 2 +#define SEEK_SET 3 /* Maximum number of unique filenames that tmpnam can generate. */ /* TODO: Set a useful value in TMP_MAX other than 16*16*16 */