From 1b67abbbfd558ca7a47a84cb6c76ebf55db1c828 Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Fri, 17 Mar 2000 09:03:28 +0000 Subject: 2000-03-13 Roland McGrath * sysdeps/generic/lockfile.c: Include (_IO_flockfile, _IO_funlockfile, _IO_ftrylockfile): #undef these in case defined them. (__flockfile, __funlockfile, __ftrylockfile): Functions renamed from __internal_*. (flockfile, _IO_flockfile, funlockfile, _IO_funlockfile, ftrylockfile, _IO_ftrylockfile): Fix aliases accordingly. --- sysdeps/generic/lockfile.c | 33 +++++++++++++++------------------ 1 file changed, 15 insertions(+), 18 deletions(-) (limited to 'sysdeps') diff --git a/sysdeps/generic/lockfile.c b/sysdeps/generic/lockfile.c index 143e9901dc..90e5f980f5 100644 --- a/sysdeps/generic/lockfile.c +++ b/sysdeps/generic/lockfile.c @@ -1,5 +1,5 @@ -/* lockfile - Handle locking and unlocking of stream. - Copyright (C) 1996, 1997 Free Software Foundation, Inc. +/* lockfile - Handle locking and unlocking of stream. Singlethreaded version. + Copyright (C) 1996,97,2000 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -17,44 +17,41 @@ write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -typedef int FILE; +#include +#undef _IO_flockfile +#undef _IO_funlockfile +#undef _IO_ftrylockfile void -__internal_flockfile (FILE *stream) +__flockfile (FILE *stream) { /* Do nothing. Using this version does not do any locking. */ } +weak_alias (__flockfile, flockfile); #ifdef USE_IN_LIBIO -weak_alias (__internal_flockfile, _IO_flockfile) -#else -weak_alias (__internal_flockfile, __flockfile) +weak_alias (__flockfile, _IO_flockfile) #endif -weak_alias (__internal_flockfile, flockfile); void -__internal_funlockfile (FILE *stream) +__funlockfile (FILE *stream) { /* Do nothing. Using this version does not do any locking. */ } #ifdef USE_IN_LIBIO -weak_alias (__internal_funlockfile, _IO_funlockfile) -#else -weak_alias (__internal_funlockfile, __funlockfile) +weak_alias (__funlockfile, _IO_funlockfile) #endif -weak_alias (__internal_funlockfile, funlockfile); +weak_alias (__funlockfile, funlockfile); int -__internal_ftrylockfile (FILE *stream) +__ftrylockfile (FILE *stream) { /* Do nothing. Using this version does not do any locking. */ return 1; } +weak_alias (__ftrylockfile, ftrylockfile); #ifdef USE_IN_LIBIO -weak_alias (__internal_ftrylockfile, _IO_ftrylockfile) -#else -weak_alias (__internal_ftrylockfile, __ftrylockfile) +weak_alias (__ftrylockfile, _IO_ftrylockfile) #endif -weak_alias (__internal_ftrylockfile, ftrylockfile); -- cgit 1.4.1