summaryrefslogtreecommitdiff
path: root/lib/libc/gen/vwarnx.c
diff options
context:
space:
mode:
authorFederico G. Schwindt <fgsch@cvs.openbsd.org>2002-06-12 03:16:21 +0000
committerFederico G. Schwindt <fgsch@cvs.openbsd.org>2002-06-12 03:16:21 +0000
commitec1ec41f703fd79fe5c2cfc5a5b1aaa82d82095a (patch)
treeb00046446f32f05315208d9de3738bfb37ad2587 /lib/libc/gen/vwarnx.c
parentbecbcf04df2ca2e46f369832d8107762301ddaac (diff)
__indr_reference() and the definition in the same compilation unit are
a bad idea. use __weak_alias(), but for now put the definition at the bottom, since AUX_FUNC is not properly propagated to the weak definition, and will cause grief to the linker. should fix vax. tested by hin@ via LDSTATIC=-static, millert@ ok.
Diffstat (limited to 'lib/libc/gen/vwarnx.c')
-rw-r--r--lib/libc/gen/vwarnx.c11
1 files changed, 4 insertions, 7 deletions
diff --git a/lib/libc/gen/vwarnx.c b/lib/libc/gen/vwarnx.c
index dbc56b1ca1e..1099072d7b2 100644
--- a/lib/libc/gen/vwarnx.c
+++ b/lib/libc/gen/vwarnx.c
@@ -32,7 +32,7 @@
*/
#if defined(LIBC_SCCS) && !defined(lint)
-static char rcsid[] = "$OpenBSD: vwarnx.c,v 1.4 2002/06/08 04:52:55 fgsch Exp $";
+static char rcsid[] = "$OpenBSD: vwarnx.c,v 1.5 2002/06/12 03:16:20 fgsch Exp $";
#endif /* LIBC_SCCS and not lint */
#include <sys/cdefs.h>
@@ -40,12 +40,6 @@ static char rcsid[] = "$OpenBSD: vwarnx.c,v 1.4 2002/06/08 04:52:55 fgsch Exp $"
#include <stdio.h>
#include <stdarg.h>
-#ifdef __indr_reference
-__indr_reference(_vwarnx, vwarnx);
-#else
-__weak_alias(vwarnx, _vwarnx);
-#endif
-
extern char *__progname; /* Program name, from crt0. */
void
@@ -58,3 +52,6 @@ _vwarnx(fmt, ap)
(void)vfprintf(stderr, fmt, ap);
(void)fprintf(stderr, "\n");
}
+
+__weak_alias(vwarnx, _vwarnx);
+