mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-10 09:32:06 +00:00
Modifications for address sanitizer [#METR-2944].
This commit is contained in:
parent
dad7c09a02
commit
abbb80ddd9
@ -90,3 +90,12 @@
|
||||
#if !defined(__x86_64__) && !defined(__aarch64__)
|
||||
#error PLATFORM_NOT_SUPPORTED
|
||||
#endif
|
||||
|
||||
/// Проверка наличия address sanitizer
|
||||
#if defined(__has_feature)
|
||||
#if __has_feature(address_sanitizer)
|
||||
#define ADDRESS_SANITIZER 1
|
||||
#endif
|
||||
#elif defined(__SANITIZE_ADDRESS__)
|
||||
#define ADDRESS_SANITIZER 1
|
||||
#endif
|
||||
|
@ -686,7 +686,14 @@ void BaseDaemon::initialize(Application& self)
|
||||
rlim.rlim_cur = config().getUInt64("core_dump.size_limit", 1024 * 1024 * 1024);
|
||||
|
||||
if (setrlimit(RLIMIT_CORE, &rlim))
|
||||
{
|
||||
#ifndef ADDRESS_SANITIZER
|
||||
throw Poco::Exception("Cannot setrlimit");
|
||||
#else
|
||||
/// Не работает под address sanitizer. http://lists.llvm.org/pipermail/llvm-bugs/2013-April/027880.html
|
||||
std::cerr << "Cannot setrlimit\n";
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
task_manager.reset(new Poco::TaskManager);
|
||||
|
Loading…
Reference in New Issue
Block a user