com.sonar.cpp.analyzer.Analyzer$AnalyzerException: Exit code != 0

Hello @kr.st.je,

Thank to the reproducer you provided us, I’ve been able to reproduce the issue on my side. This is a know issue (see CPP-2696) related to the fact we are using clang to analyze the code, and clang does not play well with boost on Windows. You can see in one of the boost headers:

  template <typename Executor>
  friend BOOST_ASIO_CONSTEXPR blocking_t query(
      const Executor& ex, convertible_from_blocking_t,
      typename enable_if<
        can_query<const Executor&, possibly_t>::value
      >::type* = 0)
#if !defined(__clang__) // Clang crashes if noexcept is used here.
#if defined(BOOST_ASIO_MSVC) // Visual C++ wants the type to be qualified.
    BOOST_ASIO_NOEXCEPT_IF((
      is_nothrow_query<const Executor&, blocking_t<>::possibly_t>::value))
#else // defined(BOOST_ASIO_MSVC)
    BOOST_ASIO_NOEXCEPT_IF((
      is_nothrow_query<const Executor&, possibly_t>::value))
#endif // defined(BOOST_ASIO_MSVC)
#endif // !defined(__clang__)
  {
    return boost::asio::query(ex, possibly_t());
  }

Notice the comment // Clang crashes if noexcept is used here.… This is exactly where the analysis crashes in the reproducer.

The good news it that there is a workaround. If you add -DBOOST_ASIO_DISABLE_NOEXCEPT to your build, the analysis no longer crashes.

I hope this helps!