Libraries updates and cleanup

* Updating common/lib
 * Updating lib/csu
 * Updating lib/libc
 * Updating libexec/ld.elf_so
 * Corrected test on __minix in featuretest to actually follow the
   meaning of the comment.
 * Cleaned up _REENTRANT-related defintions.
 * Disabled -D_REENTRANT for libfetch
 * Removing some unneeded __NBSD_LIBC defines and tests

Change-Id: Ic1394baef74d11b9f86b312f5ff4bbc3cbf72ce2
This commit is contained in:
2012-11-15 12:06:41 +01:00
parent f6aac1c3b5
commit f14fb60209
1285 changed files with 44244 additions and 14308 deletions

View File

@@ -1,4 +1,4 @@
/* $NetBSD: wcsspn.c,v 1.3 2001/09/21 16:09:15 yamt Exp $ */
/* $NetBSD: wcsspn.c,v 1.4 2011/11/21 15:02:48 joerg Exp $ */
/*-
* Copyright (c)1999,2001 Citrus Project,
@@ -29,17 +29,13 @@
*/
#include <sys/cdefs.h>
#if defined(LIBC_SCCS) && !defined(lint)
__RCSID("$NetBSD: wcsspn.c,v 1.3 2001/09/21 16:09:15 yamt Exp $");
#endif /* LIBC_SCCS and not lint */
__RCSID("$NetBSD: wcsspn.c,v 1.4 2011/11/21 15:02:48 joerg Exp $");
#include <assert.h>
#include <wchar.h>
size_t
wcsspn(s, set)
const wchar_t *s;
const wchar_t *set;
wcsspn(const wchar_t *s, const wchar_t *set)
{
const wchar_t *p;
const wchar_t *q;
@@ -47,19 +43,14 @@ wcsspn(s, set)
_DIAGASSERT(s != NULL);
_DIAGASSERT(set != NULL);
p = s;
while (*p) {
q = set;
while (*q) {
for (p = s; *p; ++p) {
for (q = set; *q; ++q) {
if (*p == *q)
break;
q++;
}
if (!*q)
goto done;
p++;
break;
}
done:
return (p - s);
}