Skip to content

Commit

Permalink
test uv_barrier_t size in right block (#35)
Browse files Browse the repository at this point in the history
  • Loading branch information
semarie committed Feb 12, 2024
1 parent afa1c67 commit 344a3f5
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/thread-common.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@
#include <pthread.h>
#endif

#if defined(PTHREAD_BARRIER_SERIAL_THREAD)
STATIC_ASSERT(sizeof(uv_barrier_t) == sizeof(pthread_barrier_t));
#endif

/* Note: guard clauses should match uv_barrier_t's in include/uv/unix.h. */
#if defined(_AIX) || \
defined(__OpenBSD__) || \
Expand Down Expand Up @@ -113,6 +109,8 @@ void uv_barrier_destroy(uv_barrier_t* barrier) {

#else

STATIC_ASSERT(sizeof(uv_barrier_t) == sizeof(pthread_barrier_t));

int uv_barrier_init(uv_barrier_t* barrier, unsigned int count) {
return UV__ERR(pthread_barrier_init(barrier, NULL, count));
}
Expand Down

0 comments on commit 344a3f5

Please sign in to comment.