From 99170750a9f9f6fd08359d1924ee605c1d03b07d Mon Sep 17 00:00:00 2001 From: "Niall Douglas (s [underscore] sourceforge {at} nedprod [dot] com)" Date: Fri, 4 Sep 2020 20:20:26 +0100 Subject: Fix a subtle race condition in map_handle on Windows where if many threads are currently allocating and freeing maps, it could rarely occur that one thread would free the map of another thread. The newly rewritten v3 of win32_maps_apply() we really, really hope is the last time! --- cmake/QuickCppLibBootstrap.cmake | 10 +++++++++- cmake/tests.cmake | 1 + 2 files changed, 10 insertions(+), 1 deletion(-) (limited to 'cmake') diff --git a/cmake/QuickCppLibBootstrap.cmake b/cmake/QuickCppLibBootstrap.cmake index 29a0a830..8efa0b26 100644 --- a/cmake/QuickCppLibBootstrap.cmake +++ b/cmake/QuickCppLibBootstrap.cmake @@ -28,12 +28,20 @@ foreach(item ${CMAKE_MODULE_PATH}) set(quickcpplib_done ON) endif() endforeach() +if(DEFINED quickcpplib_DIR) + find_package(quickcpplib QUIET CONFIG) + if(quickcpplib_FOUND) + set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${quickcpplib_DIR}/cmakelib") + set(CTEST_QUICKCPPLIB_SCRIPTS "${quickcpplib_DIR}/scripts") + set(quickcpplib_done ON) + endif() +endif() if(NOT quickcpplib_done) # CMAKE_SOURCE_DIR is the very topmost parent cmake project # CMAKE_CURRENT_SOURCE_DIR is the current cmake subproject if(NOT DEFINED CTEST_QUICKCPPLIB_CLONE_DIR) - # If there is a magic .quickcpplib_use_siblings directory above the topmost project, use sibling edition if(EXISTS "${CMAKE_SOURCE_DIR}/../.quickcpplib_use_siblings" AND NOT QUICKCPPLIB_DISABLE_SIBLINGS) + # If there is a magic .quickcpplib_use_siblings directory above the topmost project, use sibling edition set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/../quickcpplib/cmakelib") set(CTEST_QUICKCPPLIB_SCRIPTS "${CMAKE_SOURCE_DIR}/../quickcpplib/scripts") # Copy latest version of myself into end user diff --git a/cmake/tests.cmake b/cmake/tests.cmake index 0bf01f1f..8448643e 100644 --- a/cmake/tests.cmake +++ b/cmake/tests.cmake @@ -12,6 +12,7 @@ set(llfio_TESTS "test/tests/file_handle_create_close/runner.cpp" "test/tests/file_handle_lock_unlock.cpp" "test/tests/handle_adapter_xor.cpp" + "test/tests/issue0009.cpp" "test/tests/issue0027.cpp" "test/tests/issue0028.cpp" "test/tests/large_pages.cpp" -- cgit v1.2.3