Module Name: src Committed By: kamil Date: Sun Jan 7 15:28:34 UTC 2018
Modified Files: src/lib/libc/include: namespace.h src/lib/libc/stdlib: atoi.c src/sys/external/bsd/compiler_rt/dist/lib/profile: InstrProfilingFile.c Log Message: Revert namespacing of atoi(3) Sanitizers can handle recursive interceptions in some / most cases, if they will cause damage the problem will be not workaroundable without libc changes - I will be back to it. Keep namespace of asctime() as this can be a cancellation point according to POSIX. Right now it's not implemented on NetBSD. Defer it for later. Keep weak symbols and namespace for wait6(2) as this could be a cancellation point as well. Defer this for later. Sanitizers's [recursive] interceptors are a hack and moving one way or another can cause new sets of problems. Recursive ones can be useful and cause problems (on Linux there are known with with signal handlers). Sponsored by <The NetBSD Foundation> To generate a diff of this commit: cvs rdiff -u -r1.193 -r1.194 src/lib/libc/include/namespace.h cvs rdiff -u -r1.13 -r1.14 src/lib/libc/stdlib/atoi.c cvs rdiff -u -r1.2 -r1.3 \ src/sys/external/bsd/compiler_rt/dist/lib/profile/InstrProfilingFile.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/lib/libc/include/namespace.h diff -u src/lib/libc/include/namespace.h:1.193 src/lib/libc/include/namespace.h:1.194 --- src/lib/libc/include/namespace.h:1.193 Fri Jan 5 20:30:51 2018 +++ src/lib/libc/include/namespace.h Sun Jan 7 15:28:33 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: namespace.h,v 1.193 2018/01/05 20:30:51 kamil Exp $ */ +/* $NetBSD: namespace.h,v 1.194 2018/01/07 15:28:33 kamil Exp $ */ /*- * Copyright (c) 1997-2004 The NetBSD Foundation, Inc. @@ -217,7 +217,6 @@ #define asprintf_l _asprintf_l #define asysctl _asysctl #define asysctlbyname _asysctlbyname -#define atoi _atoi #define atoll _atoll #define authnone_create _authnone_create #define authunix_create _authunix_create Index: src/lib/libc/stdlib/atoi.c diff -u src/lib/libc/stdlib/atoi.c:1.13 src/lib/libc/stdlib/atoi.c:1.14 --- src/lib/libc/stdlib/atoi.c:1.13 Fri Jan 5 20:30:51 2018 +++ src/lib/libc/stdlib/atoi.c Sun Jan 7 15:28:33 2018 @@ -1,4 +1,4 @@ -/* $NetBSD: atoi.c,v 1.13 2018/01/05 20:30:51 kamil Exp $ */ +/* $NetBSD: atoi.c,v 1.14 2018/01/07 15:28:33 kamil Exp $ */ /* * Copyright (c) 1988, 1993 @@ -34,19 +34,13 @@ #if 0 static char sccsid[] = "@(#)atoi.c 8.1 (Berkeley) 6/4/93"; #else -__RCSID("$NetBSD: atoi.c,v 1.13 2018/01/05 20:30:51 kamil Exp $"); +__RCSID("$NetBSD: atoi.c,v 1.14 2018/01/07 15:28:33 kamil Exp $"); #endif #endif /* LIBC_SCCS and not lint */ -#include "namespace.h" - #include <assert.h> #include <stdlib.h> -#ifdef __weak_alias -__weak_alias(atoi,_atoi) -#endif - int atoi(const char *str) { Index: src/sys/external/bsd/compiler_rt/dist/lib/profile/InstrProfilingFile.c diff -u src/sys/external/bsd/compiler_rt/dist/lib/profile/InstrProfilingFile.c:1.2 src/sys/external/bsd/compiler_rt/dist/lib/profile/InstrProfilingFile.c:1.3 --- src/sys/external/bsd/compiler_rt/dist/lib/profile/InstrProfilingFile.c:1.2 Fri Jan 5 20:30:51 2018 +++ src/sys/external/bsd/compiler_rt/dist/lib/profile/InstrProfilingFile.c Sun Jan 7 15:28:34 2018 @@ -7,10 +7,6 @@ |* \*===----------------------------------------------------------------------===*/ -#ifdef _LIBC -#include "namespace.h" -#endif - #include "InstrProfiling.h" #include "InstrProfilingInternal.h" #include "InstrProfilingUtil.h"