Overview
Comment: | Define of_thread_current without the (). This way, it's possible to get a pointer to the actual function. |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
376cff4c0bbb7db3376342f5a49e37df |
User & Date: | js on 2011-10-22 16:14:46 |
Other Links: | manifest | tags |
Context
2011-10-22
| ||
16:57 | Indentation fix. check-in: 7da45d5ccf user: js tags: trunk | |
16:14 |
Define of_thread_current without the (). This way, it's possible to get a pointer to the actual function. check-in: 376cff4c0b user: js tags: trunk | |
2011-10-19
| ||
15:00 | Small documentation fix. check-in: a1bfe7c4b7 user: js tags: trunk | |
Changes
Modified src/threading.h from [e3a63de0b8] to [c9df66742a].
︙ | ︙ | |||
47 48 49 50 51 52 53 | typedef pthread_spinlock_t of_spinlock_t; #else typedef of_mutex_t of_spinlock_t; #endif #if defined(OF_HAVE_PTHREADS) # define of_thread_is_current(t) pthread_equal(t, pthread_self()) | | | | 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 | typedef pthread_spinlock_t of_spinlock_t; #else typedef of_mutex_t of_spinlock_t; #endif #if defined(OF_HAVE_PTHREADS) # define of_thread_is_current(t) pthread_equal(t, pthread_self()) # define of_thread_current pthread_self #elif defined(_WIN32) # define of_thread_is_current(t) (t == GetCurrentThread()) # define of_thread_current GetCurrentThread #endif static OF_INLINE BOOL of_thread_new(of_thread_t *thread, id (*main)(id), id data) { #if defined(OF_HAVE_PTHREADS) return !pthread_create(thread, NULL, (void*(*)(void*))main, |
︙ | ︙ |