1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-11 09:50:12 +00:00

Move the declaration of __cleanup to libc_private.h as it is used in both

stdio/ and stdlib/.  Don't define __cleanup twice.
This commit is contained in:
Stefan Farfeleder 2005-09-12 13:46:32 +00:00
parent 8621e8a737
commit 2ba64027bc
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=150040
5 changed files with 13 additions and 5 deletions

View File

@ -135,4 +135,9 @@ extern const char *__progname;
*/
extern struct _spinlock *__malloc_lock;
/*
* Function to clean up streams, called from abort() and exit().
*/
extern void (*__cleanup)(void);
#endif /* _LIBC_PRIVATE_H_ */

View File

@ -65,7 +65,6 @@ extern fpos_t __sseek(void *, fpos_t, int);
extern int __sclose(void *);
extern void __sinit(void);
extern void _cleanup(void);
extern void (*__cleanup)(void);
extern void __smakebuf(FILE *);
extern int __swhatbuf(FILE *, size_t *, int *);
extern int _fwalk(int (*)(FILE *));

View File

@ -46,9 +46,11 @@ __FBSDID("$FreeBSD$");
#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#include "local.h"
#include "un-namespace.h"
#include "libc_private.h"
#include "local.h"
/*
* Allocate a file buffer, or switch to unbuffered I/O.
* Per the ANSI C standard, ALL tty devices default to line buffered.

View File

@ -45,7 +45,7 @@ __FBSDID("$FreeBSD$");
#include <pthread.h>
#include "un-namespace.h"
void (*__cleanup)();
#include "libc_private.h"
void
abort()

View File

@ -41,9 +41,11 @@ __FBSDID("$FreeBSD$");
#include <stdlib.h>
#include <unistd.h>
#include "un-namespace.h"
#include "atexit.h"
void (*__cleanup)();
#include "atexit.h"
#include "libc_private.h"
void (*__cleanup)(void);
/*
* This variable is zero until a process has created a thread.