Remove the dummy stack attr routines -- best to catch broken applications
and fix them to use the proper feature test instead (as has already been done with the openldap package).
This commit is contained in:
parent
592409d356
commit
9b29af3e07
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pthread.h,v 1.6 2003/01/19 19:41:44 skrll Exp $ */
|
||||
/* $NetBSD: pthread.h,v 1.7 2003/01/19 20:58:00 thorpej Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2001 The NetBSD Foundation, Inc.
|
||||
@ -66,12 +66,6 @@ int pthread_attr_getschedparam(const pthread_attr_t *,
|
||||
struct sched_param *);
|
||||
int pthread_attr_setschedparam(pthread_attr_t *,
|
||||
const struct sched_param *);
|
||||
int pthread_attr_getstacksize(const pthread_attr_t *, size_t *);
|
||||
int pthread_attr_setstacksize(pthread_attr_t *, size_t);
|
||||
int pthread_attr_getguardsize(const pthread_attr_t *, size_t *);
|
||||
int pthread_attr_setguardsize(pthread_attr_t *, size_t);
|
||||
int pthread_attr_getstackaddr(const pthread_attr_t *, void **);
|
||||
int pthread_attr_setstackaddr(pthread_attr_t *, void *);
|
||||
int pthread_attr_getdetachstate(const pthread_attr_t *, int *);
|
||||
int pthread_attr_setdetachstate(pthread_attr_t *, int);
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pthread_stack.c,v 1.4 2003/01/19 16:03:50 christos Exp $ */
|
||||
/* $NetBSD: pthread_stack.c,v 1.5 2003/01/19 20:58:01 thorpej Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2001 The NetBSD Foundation, Inc.
|
||||
@ -149,63 +149,3 @@ pthread__stackid_setup(void *base, int size)
|
||||
|
||||
return t;
|
||||
}
|
||||
|
||||
int
|
||||
pthread_attr_getguardsize(const pthread_attr_t *attr, size_t *size)
|
||||
{
|
||||
if ((attr == NULL) || (attr->pta_magic != PT_ATTR_MAGIC)
|
||||
|| size == NULL)
|
||||
return EINVAL;
|
||||
*size = (size_t)sysconf(_SC_PAGESIZE);
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
pthread_attr_setguardsize(pthread_attr_t *attr, size_t size)
|
||||
{
|
||||
if ((attr == NULL) || (attr->pta_magic != PT_ATTR_MAGIC)
|
||||
|| size < (size_t)sysconf(_SC_PAGESIZE))
|
||||
return EINVAL;
|
||||
/*XXX*/
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
pthread_attr_getstacksize(const pthread_attr_t *attr, size_t *size)
|
||||
{
|
||||
if ((attr == NULL) || (attr->pta_magic != PT_ATTR_MAGIC)
|
||||
|| size == NULL)
|
||||
return EINVAL;
|
||||
*size = PT_STACKSIZE - 2 * (size_t)sysconf(_SC_PAGESIZE);
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
pthread_attr_setstacksize(pthread_attr_t *attr, size_t size)
|
||||
{
|
||||
if ((attr == NULL) || (attr->pta_magic != PT_ATTR_MAGIC)
|
||||
|| size < PT_STACKSIZE - 2 * (size_t)sysconf(_SC_PAGESIZE))
|
||||
return EINVAL;
|
||||
/*XXX*/
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
/*ARGSUSED*/
|
||||
pthread_attr_getstackaddr(const pthread_attr_t *attr, void **base)
|
||||
{
|
||||
if ((attr == NULL) || (attr->pta_magic != PT_ATTR_MAGIC))
|
||||
return EINVAL;
|
||||
/*XXX*/
|
||||
return 0;
|
||||
}
|
||||
|
||||
int
|
||||
/*ARGSUSED*/
|
||||
pthread_attr_setstackaddr(pthread_attr_t *attr, void *base)
|
||||
{
|
||||
if ((attr == NULL) || (attr->pta_magic != PT_ATTR_MAGIC))
|
||||
return EINVAL;
|
||||
/*XXX*/
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user