diff options
author | kazu <kazu@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-06-04 11:30:46 +0000 |
---|---|---|
committer | kazu <kazu@138bc75d-0d04-0410-961f-82ee72b054a4> | 2002-06-04 11:30:46 +0000 |
commit | 3cfec666406d71f8b7d7abcf9883c64117453c15 (patch) | |
tree | e46147f472cc001827083ec7631a1140948ce7c6 /gcc/gthr-dce.h | |
parent | a2dd943a80f4e3091f7f992594f6e3e01ce522fb (diff) | |
download | gcc-3cfec666406d71f8b7d7abcf9883c64117453c15.tar.gz |
* gbl-ctors.h: Fix formatting.
* gcc.c: Likewise.
* gccspec.c: Likewise.
* gcov.c: Likewise.
* gcov-io.h: Likewise.
* gcse.c: Likewise.
* ggc-common.c: Likewise.
* ggc.h: Likewise.
* ggc-page.c: Likewise.
* ggc-simple.c: Likewise.
* global.c: Likewise.
* graph.h: Likewise.
* gthr-dce.h: Likewise.
* gthr.h: Likewise.
* gthr-posix.h: Likewise.
* gthr-rtems.h: Likewise.
* gthr-solaris.h: Likewise.
* gthr-win32.h: Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54240 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/gthr-dce.h')
-rw-r--r-- | gcc/gthr-dce.h | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/gcc/gthr-dce.h b/gcc/gthr-dce.h index 957f2272924..273393b34df 100644 --- a/gcc/gthr-dce.h +++ b/gcc/gthr-dce.h @@ -146,9 +146,9 @@ __gthread_objc_thread_detach(void (*func)(void *), void *arg) if (!__gthread_active_p ()) return NULL; - + if ( !(pthread_create(&new_thread_handle, pthread_attr_default, - (void *)func, arg)) ) + (void *)func, arg)) ) { /* ??? May not work! (64bit) */ thread_id = *(objc_thread_t *)&new_thread_handle; @@ -156,7 +156,7 @@ __gthread_objc_thread_detach(void (*func)(void *), void *arg) } else thread_id = NULL; - + return thread_id; } @@ -182,7 +182,7 @@ __gthread_objc_thread_set_priority(int priority) sys_priority = (PRI_BG_MIN_NP + PRI_BG_MAX_NP) / 2; break; } - + /* Change the priority. */ if (pthread_setprio(pthread_self(), sys_priority) >= 0) return 0; @@ -200,7 +200,7 @@ __gthread_objc_thread_get_priority(void) if (__gthread_active_p ()) { if ((sys_priority = pthread_getprio(pthread_self())) >= 0) - { + { if (sys_priority >= PRI_FG_MIN_NP && sys_priority <= PRI_FG_MAX_NP) return OBJC_THREAD_INTERACTIVE_PRIORITY; @@ -292,12 +292,12 @@ __gthread_objc_mutex_allocate(objc_mutex_t mutex) mutex->backend = objc_malloc(sizeof(pthread_mutex_t)); if (pthread_mutex_init((pthread_mutex_t *)mutex->backend, - pthread_mutexattr_default)) - { - objc_free(mutex->backend); - mutex->backend = NULL; - return -1; - } + pthread_mutexattr_default)) + { + objc_free(mutex->backend); + mutex->backend = NULL; + return -1; + } } return 0; @@ -310,7 +310,7 @@ __gthread_objc_mutex_deallocate(objc_mutex_t mutex) if (__gthread_active_p ()) { if (pthread_mutex_destroy((pthread_mutex_t *)mutex->backend)) - return -1; + return -1; objc_free(mutex->backend); mutex->backend = NULL; |