Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libc/compat/gen Add a warning when we are using the libc...
details: https://anonhg.NetBSD.org/src/rev/cba092e8e257
branches: trunk
changeset: 782270:cba092e8e257
user: christos <christos%NetBSD.org@localhost>
date: Wed Oct 24 22:10:52 2012 +0000
description:
Add a warning when we are using the libc version of alloca(3).
diffstat:
lib/libc/compat/gen/Makefile.inc | 4 ++--
lib/libc/compat/gen/compat_alloca.c | 6 ++++++
2 files changed, 8 insertions(+), 2 deletions(-)
diffs (25 lines):
diff -r cf31ff535387 -r cba092e8e257 lib/libc/compat/gen/Makefile.inc
--- a/lib/libc/compat/gen/Makefile.inc Wed Oct 24 21:45:09 2012 +0000
+++ b/lib/libc/compat/gen/Makefile.inc Wed Oct 24 22:10:52 2012 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.inc,v 1.15 2012/10/10 22:52:26 christos Exp $
+# $NetBSD: Makefile.inc,v 1.16 2012/10/24 22:10:52 christos Exp $
.PATH: ${COMPATDIR}/gen
SRCS+=compat_errlist.c compat_fts.c compat___fts13.c compat___fts30.c \
@@ -9,4 +9,4 @@
compat__sys_errlist.c compat__sys_nerr.c compat__sys_siglist.c \
compat_time.c compat_utime.c compat_devname.c compat_alphasort.c \
compat_getpwent.c compat___fts32.c compat_utmp.c compat___fts50.c \
- compat___unvis13.c compat_syslog.c
+ compat___unvis13.c compat_syslog.c compat_alloca.c
diff -r cf31ff535387 -r cba092e8e257 lib/libc/compat/gen/compat_alloca.c
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/lib/libc/compat/gen/compat_alloca.c Wed Oct 24 22:10:52 2012 +0000
@@ -0,0 +1,6 @@
+#include <sys/cdefs.h>
+
+__warn_references(alloca,
+ "Warning: reference to the libc supplied alloca(3); this most likely will "
+ "not work. Please use the compiler provided version of alloca(3), by "
+ "supplying the appropriate compiler flags (e.g. not -std=c89).")
Home |
Main Index |
Thread Index |
Old Index