diff --git a/CMakeLists.txt b/CMakeLists.txt index 02621d8336..467623a309 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -422,8 +422,12 @@ set(TESTFILTER "" CACHE STRING "Filter string for ctest to selectively only run include(px4_add_gtest) if(BUILD_TESTING) - # Setting FUZZTEST_FUZZING_MODE=on enables ASAN, and is only supported with Clang - if (("${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang") OR ("${CMAKE_CXX_COMPILER_ID}" MATCHES "AppleClang")) + # Setting FUZZTEST_FUZZING_MODE=on enables ASAN, and is only supported with Clang. + # clang-cl on Windows uses the MSVC driver: ASAN there is incompatible with the + # debug C runtime (/MDd) emitted by CMake's Debug config, so keep fuzzing mode + # off on that combination and just compile fuzztest as a plain dependency. + if ((("${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang") OR ("${CMAKE_CXX_COMPILER_ID}" MATCHES "AppleClang")) + AND NOT (WIN32 AND "${CMAKE_CXX_SIMULATE_ID}" STREQUAL "MSVC")) set(FUZZTEST_FUZZING_MODE ON) endif() add_subdirectory(test) diff --git a/src/lib/drivers/led/led.cpp b/src/lib/drivers/led/led.cpp index afbdc11565..e472e859e3 100644 --- a/src/lib/drivers/led/led.cpp +++ b/src/lib/drivers/led/led.cpp @@ -64,7 +64,7 @@ public: ~LED() override = default; int init() override; - int ioctl(cdev::file_t *filp, int cmd, uintptr_t arg) override; + int ioctl(cdev::file_t *filp, int cmd, unsigned long arg) override; }; LED::LED() : CDev(LED0_DEVICE_PATH) @@ -86,7 +86,7 @@ LED::init() } int -LED::ioctl(cdev::file_t *filp, int cmd, uintptr_t arg) +LED::ioctl(cdev::file_t *filp, int cmd, unsigned long arg) { int result = OK;