This is the mail archive of the libc-hacker@sources.redhat.com mailing list for the glibc project.

Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Further prototype warnings removal



Another patch to remove a number of warnings about prototypes.  Ok to
commit?

Andreas

2000-12-26  Andreas Jaeger  <aj@suse.de>

	* libio/getc_u.c: Include stdio.h via system path to get internal
	prototypes.
	* libio/getwc_u.c: Likewise.

	* stdlib/strfmon.c: Fix prototype of __printf_fp.

	* stdio-common/vfprintf.c (process_arg): Move __printf_fphex and
	__printf_fp prototypes to ...
	* include/printf.h: ...here.

	* include/stdio.h: Add some prototypes to shut up GCC.
	* include/stdlib.h: Likewise.

	* sysdeps/posix/sigpause.c (__sigpause): Use ISO C prototype
	declaration.

	* include/signal.h: Add prototypes for internal sigpause
	interfaces.

============================================================
Index: include/signal.h
--- include/signal.h	2000/07/07 00:44:21	1.6
+++ include/signal.h	2000/12/26 19:34:01
@@ -26,6 +26,12 @@
 extern int __libc_sigaction (int sig, const struct sigaction *act,
 			     struct sigaction *oact);
 
+extern int __sigpause (int sig_or_mask, int is_sig);
+extern int __default_sigpause (int mask);
+extern int __xpg_sigpause (int sig);
+
+
+
 /* Allocate real-time signal with highest/lowest available priority.  */
 extern int __libc_allocate_rtsig (int __high);
 #endif
============================================================
Index: include/stdio.h
--- include/stdio.h	2000/12/22 09:00:17	1.12
+++ include/stdio.h	2000/12/26 19:34:01
@@ -60,6 +60,10 @@
    possible.  */
 extern int __ftrylockfile (FILE *__stream);
 
+extern int __getc_unlocked (FILE *__fp);
+extern wint_t __getwc_unlocked (FILE *__fp);
+
+
 # endif
 
 #endif
============================================================
Index: include/stdlib.h
--- include/stdlib.h	2000/08/23 07:22:36	1.13
+++ include/stdlib.h	2000/12/26 19:34:01
@@ -55,8 +55,12 @@
 
 extern int __cxa_atexit (void (*func) (void *), void *arg, void *d);
 
+extern void __cxa_finalize (void *d);
+
 extern int __posix_memalign (void **memptr, size_t alignment, size_t size)
      __attribute_malloc__;
+
+extern int __libc_system (const char *line);
 
 #endif
 #undef __Need_M_And_C
============================================================
Index: include/printf.h
--- include/printf.h	1997/06/21 01:17:46	1.1
+++ include/printf.h	2000/12/26 19:34:01
@@ -1 +1,11 @@
+#ifndef	_PRINTF_H
+
 #include <stdio-common/printf.h>
+
+/* Now define the internal interfaces.  */
+extern int __printf_fphex (FILE *, const struct printf_info *,
+			   const void *const *);
+extern int __printf_fp (FILE *, const struct printf_info *,
+			const void *const *);
+
+#endif
============================================================
Index: sysdeps/posix/sigpause.c
--- sysdeps/posix/sigpause.c	2000/08/21 04:16:36	1.12
+++ sysdeps/posix/sigpause.c	2000/12/26 19:34:02
@@ -23,9 +23,7 @@
 /* Set the mask of blocked signals to MASK,
    wait for a signal to arrive, and then restore the mask.  */
 int
-__sigpause (sig_or_mask, is_sig)
-     int sig_or_mask;
-     int is_sig;
+__sigpause (int sig_or_mask, int is_sig)
 {
   sigset_t set;
   int sig;
============================================================
Index: stdio-common/vfprintf.c
--- stdio-common/vfprintf.c	2000/09/25 05:10:26	1.97
+++ stdio-common/vfprintf.c	2000/12/26 19:34:04
@@ -798,8 +798,6 @@
     LABEL (form_float):							      \
       {									      \
 	/* Floating-point number.  This is handled by printf_fp.c.  */	      \
-	extern int __printf_fp __P ((FILE *, const struct printf_info *,      \
-				     const void **const));		      \
 	const void *ptr;						      \
 	int function_done;						      \
 									      \
@@ -848,9 +846,7 @@
 									      \
     LABEL (form_floathex):						      \
       {									      \
-        /* FLoating point number printed as hexadecimal number.  */	      \
-	extern int __printf_fphex __P ((FILE *, const struct printf_info *,   \
-					const void **const));		      \
+        /* Floating point number printed as hexadecimal number.  */	      \
 	const void *ptr;						      \
 	int function_done;						      \
 									      \
@@ -919,7 +915,7 @@
 	else								      \
 	  {								      \
 	    /* Write "(nil)" for a nil pointer.  */			      \
-	    string = (CHAR_T *) L_("(nil)");	 			      \
+	    string = (CHAR_T *) L_("(nil)");				      \
 	    /* Make sure the full string "(nil)" is printed.  */	      \
 	    if (prec < 5)						      \
 	      prec = 5;							      \
============================================================
Index: stdlib/strfmon.c
--- stdlib/strfmon.c	2000/07/01 00:37:33	1.17
+++ stdlib/strfmon.c	2000/12/26 19:34:05
@@ -74,7 +74,7 @@
 #endif
 
 extern int __printf_fp (FILE *, const struct printf_info *,
-			const void **const);
+			const void *const *);
 /* This function determines the number of digit groups in the output.
    The definition is in printf_fp.c.  */
 extern unsigned int __guess_grouping (unsigned int intdig_max,
============================================================
Index: libio/getwc_u.c
--- libio/getwc_u.c	1999/06/16 22:03:56	1.1
+++ libio/getwc_u.c	2000/12/26 19:34:05
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 1995, 1996, 1997, 1999 Free Software Foundation, Inc.
+/* Copyright (C) 1993,1995,1996,1997,1999,2000  Free Software Foundation, Inc.
    This file is part of the GNU IO Library.
 
    This library is free software; you can redistribute it and/or
@@ -24,7 +24,7 @@
    General Public License.  */
 
 #include "libioP.h"
-#include "stdio.h"
+#include <stdio.h>
 
 #undef getwc_unlocked
 
============================================================
Index: libio/getc_u.c
--- libio/getc_u.c	1999/01/28 12:40:28	1.6
+++ libio/getc_u.c	2000/12/26 19:34:05
@@ -1,4 +1,4 @@
-/* Copyright (C) 1993, 1995, 1996, 1997, 1999 Free Software Foundation, Inc.
+/* Copyright (C) 1993,1995,1996,1997,1999,2000 Free Software Foundation, Inc.
    This file is part of the GNU IO Library.
 
    This library is free software; you can redistribute it and/or
@@ -24,7 +24,7 @@
    General Public License.  */
 
 #include "libioP.h"
-#include "stdio.h"
+#include <stdio.h>
 
 #undef getc_unlocked
 

-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]