OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
234 RTC_DCHECK_RUN_ON(thread_); | 234 RTC_DCHECK_RUN_ON(thread_); |
235 function(); | 235 function(); |
236 } | 236 } |
237 | 237 |
238 void access_fun_and_var() { | 238 void access_fun_and_var() { |
239 RTC_DCHECK_RUN_ON(thread_); | 239 RTC_DCHECK_RUN_ON(thread_); |
240 fun_acccess_var(); | 240 fun_acccess_var(); |
241 } | 241 } |
242 | 242 |
243 private: | 243 private: |
244 void function() RUN_ON(thread_) {} | 244 void function() RTC_RUN_ON(thread_) {} |
245 void fun_acccess_var() RUN_ON(thread_) { var_thread_ = 13; } | 245 void fun_acccess_var() RTC_RUN_ON(thread_) { var_thread_ = 13; } |
246 | 246 |
247 rtc::Thread* thread_; | 247 rtc::Thread* thread_; |
248 rtc::ThreadChecker checker_; | 248 rtc::ThreadChecker checker_; |
249 rtc::TaskQueue* queue_; | 249 rtc::TaskQueue* queue_; |
250 | 250 |
251 int var_thread_ ACCESS_ON(thread_); | 251 int var_thread_ RTC_ACCESS_ON(thread_); |
252 int var_checker_ GUARDED_BY(checker_); | 252 int var_checker_ RTC_GUARDED_BY(checker_); |
253 int var_queue_ ACCESS_ON(queue_); | 253 int var_queue_ RTC_ACCESS_ON(queue_); |
254 }; | 254 }; |
255 | 255 |
256 // Just in case we ever get lumped together with other compilation units. | 256 // Just in case we ever get lumped together with other compilation units. |
257 #undef ENABLE_THREAD_CHECKER | 257 #undef ENABLE_THREAD_CHECKER |
258 | 258 |
259 } // namespace rtc | 259 } // namespace rtc |
OLD | NEW |