mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-11 08:40:44 +00:00
Reaplce pthrea_yield with sched_yield
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@10887 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
948d0ead9c
commit
cbcdd59f78
3 changed files with 12 additions and 0 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2001-09-12 Adam Fedor <fedor@gnu.org>
|
||||||
|
|
||||||
|
* Source/thr-pthread.m (objc_yield): Replace pthread_yield with
|
||||||
|
sched_yield.
|
||||||
|
|
||||||
2001-09-11 Adam Fedor <fedor@gnu.org>
|
2001-09-11 Adam Fedor <fedor@gnu.org>
|
||||||
|
|
||||||
* configure.in: Make sure to subst HAVE_PTHREAD_H into config.mak
|
* configure.in: Make sure to subst HAVE_PTHREAD_H into config.mak
|
||||||
|
|
|
@ -30,6 +30,8 @@
|
||||||
|
|
||||||
#include <objc/objc-class.h>
|
#include <objc/objc-class.h>
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
|
#include <ctype.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
|
||||||
typedef union {
|
typedef union {
|
||||||
char *arg_ptr;
|
char *arg_ptr;
|
||||||
|
|
|
@ -238,7 +238,12 @@ objc_thread_get_priority(void)
|
||||||
void
|
void
|
||||||
objc_thread_yield(void)
|
objc_thread_yield(void)
|
||||||
{
|
{
|
||||||
|
#if 0
|
||||||
|
/* Not defined in darwin? */
|
||||||
pthread_yield(NULL);
|
pthread_yield(NULL);
|
||||||
|
#else
|
||||||
|
sched_yield();
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Terminate the current thread. */
|
/* Terminate the current thread. */
|
||||||
|
|
Loading…
Reference in a new issue