Audio plugin host https://kx.studio/carla
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

null_static_mutex.hpp 1.1KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. //
  2. // detail/null_static_mutex.hpp
  3. // ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  4. //
  5. // Copyright (c) 2003-2015 Christopher M. Kohlhoff (chris at kohlhoff dot com)
  6. //
  7. // Distributed under the Boost Software License, Version 1.0. (See accompanying
  8. // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  9. //
  10. #ifndef ASIO_DETAIL_NULL_STATIC_MUTEX_HPP
  11. #define ASIO_DETAIL_NULL_STATIC_MUTEX_HPP
  12. #if defined(_MSC_VER) && (_MSC_VER >= 1200)
  13. # pragma once
  14. #endif // defined(_MSC_VER) && (_MSC_VER >= 1200)
  15. #include "asio/detail/config.hpp"
  16. #if !defined(ASIO_HAS_THREADS)
  17. #include "asio/detail/scoped_lock.hpp"
  18. #include "asio/detail/push_options.hpp"
  19. namespace asio {
  20. namespace detail {
  21. struct null_static_mutex
  22. {
  23. typedef asio::detail::scoped_lock<null_static_mutex> scoped_lock;
  24. // Initialise the mutex.
  25. void init()
  26. {
  27. }
  28. // Lock the mutex.
  29. void lock()
  30. {
  31. }
  32. // Unlock the mutex.
  33. void unlock()
  34. {
  35. }
  36. int unused_;
  37. };
  38. #define ASIO_NULL_STATIC_MUTEX_INIT { 0 }
  39. } // namespace detail
  40. } // namespace asio
  41. #include "asio/detail/pop_options.hpp"
  42. #endif // !defined(ASIO_HAS_THREADS)
  43. #endif // ASIO_DETAIL_NULL_STATIC_MUTEX_HPP