1
0
mirror of https://github.com/mariadb-corporation/mariadb-columnstore-engine.git synced 2025-04-18 21:44:02 +03:00

Turn on ASAN for unitests (#2719)

Fix asan error on compression tests
Fix warn of nonreturn function
This commit is contained in:
Leonid Fedorov 2023-02-02 16:08:01 +03:00 committed by GitHub
parent c1168e33aa
commit f7118b53a8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 2 deletions

View File

@ -1,4 +1,7 @@
include_directories( ${ENGINE_COMMON_INCLUDES} ${ENGINE_BLOCKCACHE_INCLUDE} ${ENGINE_PRIMPROC_INCLUDE} )
MY_CHECK_AND_SET_COMPILER_FLAG("-U_FORTIFY_SOURCE" DEBUG RELWITHDEBINFO)
MY_CHECK_AND_SET_COMPILER_FLAG("-fsanitize=address -fsanitize-address-use-after-scope -fPIC")
if (WITH_UNITTESTS)
cmake_policy(SET CMP0054 NEW)

View File

@ -59,7 +59,7 @@ TEST_F(CompressionTest, LZ4CanCompress)
std::unique_ptr<compress::CompressInterface> compressor(new compress::CompressInterfaceLZ4());
size_t originalSize = originalData.size();
size_t originalSize = originalData.size() + 1;
size_t compressedSize = compressor->maxCompressedSize(originalSize);
std::unique_ptr<char[]> compressedData(new char[compressedSize]);
std::memset(compressedData.get(), 0, compressedSize);

View File

@ -198,7 +198,7 @@ int64_t getSignedNullValue(CalpontSystemCatalog::ColDataType t, uint32_t colWidt
os << "getSignedNullValue(): got bad column type (" << t << "). Width=" << colWidth << endl;
throw logic_error(os.str());
}
return 0;
}
} // namespace utils