public inbox for newlib-cvs@sourceware.org
help / color / mirror / Atom feed
From: Sebastian Huber <sh@sourceware.org>
To: newlib-cvs@sourceware.org
Subject: [newlib-cygwin] Remove duplicate sglue initializations
Date: Fri, 13 May 2022 11:19:31 +0000 (GMT)	[thread overview]
Message-ID: <20220513111931.F3BC7384858D@sourceware.org> (raw)

https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=92896d4daadc3e89fc64adf468d90fee0b84f7b3

commit 92896d4daadc3e89fc64adf468d90fee0b84f7b3
Author: Matt Joyce <matthew.joyce@embedded-brains.de>
Date:   Fri Apr 1 11:32:00 2022 +0200

    Remove duplicate sglue initializations
    
    Removed duplicate sglue initializations from __sinit(). These
    are already initialized in the _REENT_INIT macro in sys/reent.h.
    This simplification enables the reduction of _GLOBAL_REENT
    dependency in a follow-on patch.

Diff:
---
 newlib/libc/stdio/findfp.c | 3 ---
 1 file changed, 3 deletions(-)

diff --git a/newlib/libc/stdio/findfp.c b/newlib/libc/stdio/findfp.c
index ab3c6a55d..8327b1992 100644
--- a/newlib/libc/stdio/findfp.c
+++ b/newlib/libc/stdio/findfp.c
@@ -246,15 +246,12 @@ __sinit (struct _reent *s)
   /* make sure we clean up on exit */
   s->__cleanup = cleanup_stdio;	/* conservative */
 
-  s->__sglue._next = NULL;
 #ifndef _REENT_SMALL
 # ifndef _REENT_GLOBAL_STDIO_STREAMS
   s->__sglue._niobs = 3;
   s->__sglue._iobs = &s->__sf[0];
 # endif /* _REENT_GLOBAL_STDIO_STREAMS */
 #else
-  s->__sglue._niobs = 0;
-  s->__sglue._iobs = NULL;
 # ifndef _REENT_GLOBAL_STDIO_STREAMS
   s->_stdin = __sfp(s);
   s->_stdout = __sfp(s);


                 reply	other threads:[~2022-05-13 11:19 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220513111931.F3BC7384858D@sourceware.org \
    --to=sh@sourceware.org \
    --cc=newlib-cvs@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).