X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/138e6f86566611611b1115c957cae0a1c6a85a4b..3f9587e71330e7471ef675d2652cee260a0e3a96:/src/xbt/xbt_os_thread.c diff --git a/src/xbt/xbt_os_thread.c b/src/xbt/xbt_os_thread.c index 60e5e13a93..6208210e1d 100644 --- a/src/xbt/xbt_os_thread.c +++ b/src/xbt/xbt_os_thread.c @@ -37,7 +37,6 @@ #include "xbt/sysdep.h" #include "xbt/ex.h" -#include "src/xbt/ex_interface.h" /* We play crude games with exceptions */ #include "src/internal_config.h" #include "xbt/xbt_os_time.h" /* Portable time facilities */ #include "xbt/xbt_os_thread.h" /* This module */ @@ -45,7 +44,7 @@ XBT_LOG_NEW_DEFAULT_SUBCATEGORY(xbt_sync_os, xbt, "Synchronization mechanism (OS-level)"); -/* use named sempahore when sem_init() does not work */ +/* use named semaphore when sem_init() does not work */ #if !HAVE_SEM_INIT static int next_sem_ID = 0; static xbt_os_mutex_t next_sem_ID_lock; @@ -251,7 +250,7 @@ void xbt_os_thread_exit(int *retval) pthread_exit(retval); } -xbt_os_thread_t xbt_os_thread_self(void) +xbt_os_thread_t xbt_os_thread_self(void ) { if (!thread_mod_inited) return NULL; @@ -452,13 +451,6 @@ void xbt_os_sem_destroy(xbt_os_sem_t sem) xbt_free(sem); } -void xbt_os_sem_get_value(xbt_os_sem_t sem, int *svalue) -{ - if (sem_getvalue(&(sem->s), svalue) < 0) - THROWF(system_error, errno, "sem_getvalue() failed: %s", - strerror(errno)); -} - /** @brief Returns the amount of cores on the current host */ int xbt_os_get_numcores(void) { #ifdef WIN32