From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1921) id EAD3738582BC; Wed, 13 Jul 2022 08:19:07 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org EAD3738582BC Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Sebastian Huber To: newlib-cvs@sourceware.org Subject: [newlib-cygwin] Move content in X-Act-Checkin: newlib-cygwin X-Git-Author: Sebastian Huber X-Git-Refname: refs/heads/master X-Git-Oldrev: 56d5a57e5fdf3ba796a332c631ef28ecc9bcf869 X-Git-Newrev: a3fe1ed573dddcfd905183e6b5fa60bd7cfa661d Message-Id: <20220713081907.EAD3738582BC@sourceware.org> Date: Wed, 13 Jul 2022 08:19:07 +0000 (GMT) X-BeenThere: newlib-cvs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Newlib GIT logs List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Jul 2022 08:19:08 -0000 https://sourceware.org/git/gitweb.cgi?p=3Dnewlib-cygwin.git;h=3Da3fe1ed573d= ddcfd905183e6b5fa60bd7cfa661d commit a3fe1ed573dddcfd905183e6b5fa60bd7cfa661d Author: Sebastian Huber Date: Wed May 18 19:21:44 2022 +0200 Move content in =20 Move definitions not directly related to struct _reent to the bottom of= the file. This allows a contiguous #ifndef _REENT_THREAD_LOCAL_STORAGE blo= ck. Diff: --- newlib/libc/include/sys/reent.h | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/newlib/libc/include/sys/reent.h b/newlib/libc/include/sys/reen= t.h index 2d144f653..e9bded6c7 100644 --- a/newlib/libc/include/sys/reent.h +++ b/newlib/libc/include/sys/reent.h @@ -725,11 +725,6 @@ struct _reent _REENT_INIT_PTR_ZEROED(var); \ } =20 -/* This value is used in stdlib/misc.c. reent/reent.c has to know it - as well to make sure the freelist is correctly free'd. Therefore - we define it here, rather than in stdlib/misc.c, as before. */ -#define _Kmax (sizeof (size_t) << 3) - /* * All references to struct _reent are via this pointer. * Internally, newlib routines that need to reference it should use _REENT. @@ -747,13 +742,6 @@ extern struct _reent *_impure_ptr __ATTRIBUTE_IMPURE_P= TR__; =20 extern struct _reent _impure_data __ATTRIBUTE_IMPURE_DATA__; =20 -extern void (*__stdio_exit_handler) (void); - -void _reclaim_reent (struct _reent *); - -extern int _fwalk_sglue (struct _reent *, int (*)(struct _reent *, __FILE = *), - struct _glue *); - /* #define _REENT_ONLY define this to get only reentrant routines */ =20 #if defined(__DYNAMIC_REENT__) && !defined(__SINGLE_THREAD__) @@ -767,9 +755,21 @@ extern int _fwalk_sglue (struct _reent *, int (*)(stru= ct _reent *, __FILE *), =20 #define _GLOBAL_REENT (&_impure_data) =20 +/* This value is used in stdlib/misc.c. reent/reent.c has to know it + as well to make sure the freelist is correctly free'd. Therefore + we define it here, rather than in stdlib/misc.c, as before. */ +#define _Kmax (sizeof (size_t) << 3) + extern struct _atexit *__atexit; /* points to head of LIFO stack */ extern struct _atexit __atexit0; /* one guaranteed table, required by ANSI= */ =20 +extern void (*__stdio_exit_handler) (void); + +void _reclaim_reent (struct _reent *); + +extern int _fwalk_sglue (struct _reent *, int (*)(struct _reent *, __FILE = *), + struct _glue *); + #ifdef __cplusplus } #endif