update cmakelists

This commit is contained in:
zvonand 2023-04-20 02:53:42 +02:00
parent b81ce64fa2
commit bf55f43e19
2 changed files with 7 additions and 2 deletions

View File

@ -191,6 +191,11 @@ list (APPEND dbms_headers
Dictionaries/DictionaryStructure.h
Dictionaries/getDictionaryConfigurationFromAST.h)
# Required for validation of Timezone in session_timezone setting.
# This way we don't need to create timezone via cctz each time, but check against pregenerated char**
list (APPEND dbms_sources
Storages/System/StorageSystemTimeZones.generated.cpp)
if (NOT ENABLE_SSL)
list (REMOVE_ITEM clickhouse_common_io_sources Common/OpenSSLHelpers.cpp)
list (REMOVE_ITEM clickhouse_common_io_headers Common/OpenSSLHelpers.h)

View File

@ -28,7 +28,7 @@ namespace ErrorCodes
namespace
{
bool checkIsExitingTimeZone(const std::string_view timezone)
bool checkIsExistingTimeZone(const std::string_view timezone)
{
for (auto * it = auto_time_zones; *it; ++it)
if (timezone == *it)
@ -475,7 +475,7 @@ void SettingFieldTimezone::readBinary(ReadBuffer & in)
void SettingFieldTimezone::validateTimezone(std::string_view str)
{
if (!str.empty() && !checkIsExitingTimeZone(str))
if (!str.empty() && !checkIsExistingTimeZone(str))
throw DB::Exception(DB::ErrorCodes::BAD_ARGUMENTS, "Invalid time zone: {}", str);
}