A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'master' of scm.gforge.inria.fr:/gitroot/simgrid/simgrid
[simgrid.git]
/
src
/
xbt
/
xbt_os_thread.c
diff --git
a/src/xbt/xbt_os_thread.c
b/src/xbt/xbt_os_thread.c
index
91db34b
..
3ef350b
100644
(file)
--- a/
src/xbt/xbt_os_thread.c
+++ b/
src/xbt/xbt_os_thread.c
@@
-17,14
+17,14
@@
#include <unistd.h>
#endif
#include <unistd.h>
#endif
-#include "internal_config.h"
+#include "
src/
internal_config.h"
#include "xbt/sysdep.h"
#include "xbt/ex.h"
#include "xbt/sysdep.h"
#include "xbt/ex.h"
-#include "xbt/ex_interface.h" /* We play crude games with exceptions */
-#include "portable.h"
+#include "
src/
xbt/ex_interface.h" /* We play crude games with exceptions */
+#include "
src/
portable.h"
#include "xbt/xbt_os_time.h" /* Portable time facilities */
#include "xbt/xbt_os_thread.h" /* This module */
#include "xbt/xbt_os_time.h" /* Portable time facilities */
#include "xbt/xbt_os_thread.h" /* This module */
-#include "xbt_modinter.h" /* Initialization/finalization of this module */
+#include "
src/
xbt_modinter.h" /* Initialization/finalization of this module */
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(xbt_sync_os, xbt,
"Synchronization mechanism (OS-level)");
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(xbt_sync_os, xbt,
"Synchronization mechanism (OS-level)");
@@
-291,14
+291,10
@@
void xbt_os_thread_exit(int *retval)
xbt_os_thread_t xbt_os_thread_self(void)
{
xbt_os_thread_t xbt_os_thread_self(void)
{
- xbt_os_thread_t res;
-
if (!thread_mod_inited)
return NULL;
if (!thread_mod_inited)
return NULL;
- res = pthread_getspecific(xbt_self_thread_key);
-
- return res;
+ return pthread_getspecific(xbt_self_thread_key);
}
void xbt_os_thread_key_create(xbt_os_thread_key_t* key) {
}
void xbt_os_thread_key_create(xbt_os_thread_key_t* key) {
@@
-1303,8
+1299,7
@@
void xbt_os_thread_set_extra_data(void *data)
void *xbt_os_thread_get_extra_data(void)
{
void *xbt_os_thread_get_extra_data(void)
{
- xbt_os_thread_t self = xbt_os_thread_self();
- return self? self->extra_data : NULL;
+ return xbt_os_thread_self()->extra_data;
}
xbt_os_rmutex_t xbt_os_rmutex_init(void)
}
xbt_os_rmutex_t xbt_os_rmutex_init(void)