message: ci: Fail if memcheck errors are identified
diff: @@ -490,7 +490,12 @@ if(dashboard_do_memcheck)
  dashboard_hook_memcheck()
  endif()
  message("Calling ctest_memcheck")
  - ctest_memcheck()
  + ctest_memcheck(RETURN_VALUE MEMCHECK_RETURN DEFECT_COUNT MEMCHECK_DEFECTS)
  + if(NOT (MEMCHECK_DEFECTS EQUAL 0))
  + message(SEND_ERROR "ctest memcheck defects found: ${MEMCHECK_DEFECTS}")
  + elseif(NOT (MEMCHECK_RETURN EQUAL 0))
  + message(SEND_ERROR "ctest memcheck return value: ${MEMCHECK_RETURN}")
  + endif()
  endif()
  if(dashboard_do_submit)
  ctest_submit(PARTS MemCheck)
  