Skip to content

Commit 4f32ba4

Browse files
author
zoybai
committed
Fixed osq_lock and tbb_spin_rw_mutex redefine warnings
1 parent 8c33399 commit 4f32ba4

File tree

2 files changed

+16
-0
lines changed

2 files changed

+16
-0
lines changed

ext/linux/osq_lock.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,14 @@
66
#ifndef __LINUX_OSQ_LOCK_H
77
#define __LINUX_OSQ_LOCK_H
88

9+
#ifdef initialize_lock
10+
#undef initialize_lock
11+
#endif
12+
13+
#ifdef parse_test_args
14+
#undef parse_test_args
15+
#endif
16+
917
#define initialize_lock(lock, threads) osq_lock_init(lock, threads)
1018
#define parse_test_args(args, argc, argv) osq_parse_args(args, argc, argv)
1119

ext/tbb/tbb_spin_rw_mutex.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,6 +123,14 @@
123123
#ifndef __TBB_spin_mutex_H
124124
#define __TBB_spin_mutex_H
125125

126+
#ifdef initialize_lock
127+
#undef initialize_lock
128+
#endif
129+
130+
#ifdef parse_test_args
131+
#undef parse_test_args
132+
#endif
133+
126134
#define initialize_lock(lock, threads) tbb_init_locks(lock, threads)
127135
#define parse_test_args(args, argc, argv) tbb_parse_args(args, argc, argv)
128136

0 commit comments

Comments
 (0)