public inbox for newlib-cvs@sourceware.org
help / color / mirror / Atom feed
* [newlib-cygwin] newlib: Rename __sfmoreglue() and make it static
@ 2022-03-31  6:24 Sebastian Huber
  0 siblings, 0 replies; only message in thread
From: Sebastian Huber @ 2022-03-31  6:24 UTC (permalink / raw)
  To: newlib-cvs

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

commit 3c722c80220ff776a24294620a39d4c086cdd8f2
Author: Sebastian Huber <sebastian.huber@embedded-brains.de>
Date:   Wed Mar 30 11:19:59 2022 +0200

    newlib: Rename __sfmoreglue() and make it static
    
    Rename __sfmoreglue() in sfmoreglue() and make it static.  This function is
    only used by __sfp() in the same translation unit.
    
    Remove use of register keyword.

Diff:
---
 newlib/libc/stdio/findfp.c | 7 +++----
 newlib/libc/stdio/local.h  | 1 -
 2 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/newlib/libc/stdio/findfp.c b/newlib/libc/stdio/findfp.c
index 7bb48e014..eca47bd92 100644
--- a/newlib/libc/stdio/findfp.c
+++ b/newlib/libc/stdio/findfp.c
@@ -122,9 +122,8 @@ struct glue_with_file {
   FILE file;
 };
 
-struct _glue *
-__sfmoreglue (struct _reent *d,
-       register int n)
+static struct _glue *
+sfmoreglue (struct _reent *d, int n)
 {
   struct glue_with_file *g;
 
@@ -160,7 +159,7 @@ __sfp (struct _reent *d)
 	if (fp->_flags == 0)
 	  goto found;
       if (g->_next == NULL &&
-	  (g->_next = __sfmoreglue (d, NDYNAMIC)) == NULL)
+	  (g->_next = sfmoreglue (d, NDYNAMIC)) == NULL)
 	break;
     }
   _newlib_sfp_lock_exit ();
diff --git a/newlib/libc/stdio/local.h b/newlib/libc/stdio/local.h
index 09ccd6407..86422eb11 100644
--- a/newlib/libc/stdio/local.h
+++ b/newlib/libc/stdio/local.h
@@ -184,7 +184,6 @@ extern void   _cleanup_r (struct _reent *);
 extern void   __smakebuf_r (struct _reent *, FILE *);
 extern int    __swhatbuf_r (struct _reent *, FILE *, size_t *, int *);
 extern int    _fwalk_reent (struct _reent *, int (*)(struct _reent *, FILE *));
-struct _glue * __sfmoreglue (struct _reent *,int n);
 extern int __submore (struct _reent *, FILE *);
 
 #ifdef __LARGE64_FILES


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2022-03-31  6:24 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-31  6:24 [newlib-cygwin] newlib: Rename __sfmoreglue() and make it static Sebastian Huber

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).