aboutsummaryrefslogtreecommitdiff
path: root/misc
diff options
context:
space:
mode:
Diffstat (limited to 'misc')
-rw-r--r--misc/err.c18
-rw-r--r--misc/getttyent.c6
-rw-r--r--misc/mntent_r.c6
3 files changed, 9 insertions, 21 deletions
diff --git a/misc/err.c b/misc/err.c
index 716f994517..2a15bac08d 100644
--- a/misc/err.c
+++ b/misc/err.c
@@ -1,5 +1,5 @@
/* 4.4BSD utility functions for error messages.
- Copyright (C) 1995,96,98,2001,02 Free Software Foundation, Inc.
+ Copyright (C) 1995,1996,1998,2001,2002,2011 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
@@ -24,11 +24,9 @@
#include <string.h>
#include <stdio.h>
-#ifdef USE_IN_LIBIO
-# include <wchar.h>
-# define flockfile(s) _IO_flockfile (s)
-# define funlockfile(s) _IO_funlockfile (s)
-#endif
+#include <wchar.h>
+#define flockfile(s) _IO_flockfile (s)
+#define funlockfile(s) _IO_funlockfile (s)
extern char *__progname;
@@ -40,11 +38,10 @@ extern char *__progname;
va_end (ap); \
}
-#ifdef USE_IN_LIBIO
static void
convert_and_print (const char *format, __gnuc_va_list ap)
{
-# define ALLOCA_LIMIT 2000
+#define ALLOCA_LIMIT 2000
size_t len;
wchar_t *wformat = NULL;
mbstate_t st;
@@ -85,13 +82,11 @@ convert_and_print (const char *format, __gnuc_va_list ap)
__vfwprintf (stderr, wformat, ap);
}
-#endif
void
vwarnx (const char *format, __gnuc_va_list ap)
{
flockfile (stderr);
-#ifdef USE_IN_LIBIO
if (_IO_fwide (stderr, 0) > 0)
{
__fwprintf (stderr, L"%s: ", __progname);
@@ -99,7 +94,6 @@ vwarnx (const char *format, __gnuc_va_list ap)
putwc_unlocked (L'\n', stderr);
}
else
-#endif
{
fprintf (stderr, "%s: ", __progname);
if (format)
@@ -116,7 +110,6 @@ vwarn (const char *format, __gnuc_va_list ap)
int error = errno;
flockfile (stderr);
-#ifdef USE_IN_LIBIO
if (_IO_fwide (stderr, 0) > 0)
{
__fwprintf (stderr, L"%s: ", __progname);
@@ -129,7 +122,6 @@ vwarn (const char *format, __gnuc_va_list ap)
__fwprintf (stderr, L"%m\n");
}
else
-#endif
{
fprintf (stderr, "%s: ", __progname);
if (format)
diff --git a/misc/getttyent.c b/misc/getttyent.c
index 7560170890..6d789c4e2e 100644
--- a/misc/getttyent.c
+++ b/misc/getttyent.c
@@ -37,10 +37,8 @@ static char sccsid[] = "@(#)getttyent.c 8.1 (Berkeley) 6/4/93";
#include <ctype.h>
#include <string.h>
-#ifdef USE_IN_LIBIO
-# define flockfile(s) _IO_flockfile (s)
-# define funlockfile(s) _IO_funlockfile (s)
-#endif
+#define flockfile(s) _IO_flockfile (s)
+#define funlockfile(s) _IO_funlockfile (s)
static char zapchar;
static FILE *tf;
diff --git a/misc/mntent_r.c b/misc/mntent_r.c
index 6959f0e21d..0e9835c61e 100644
--- a/misc/mntent_r.c
+++ b/misc/mntent_r.c
@@ -25,10 +25,8 @@
#include <string.h>
#include <sys/types.h>
-#ifdef USE_IN_LIBIO
-# define flockfile(s) _IO_flockfile (s)
-# define funlockfile(s) _IO_funlockfile (s)
-#endif
+#define flockfile(s) _IO_flockfile (s)
+#define funlockfile(s) _IO_funlockfile (s)
#undef __setmntent
#undef __endmntent