Remove false-positive warning

This commit is contained in:
alesapin 2020-09-09 17:43:17 +03:00
parent 956138635d
commit 50dee3f449

View File

@ -29,6 +29,9 @@ String MergeTreePartition::getID(const MergeTreeData & storage) const
return getID(storage.getInMemoryMetadataPtr()->getPartitionKey().sample_block);
}
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wstringop-overflow"
/// NOTE: This ID is used to create part names which are then persisted in ZK and as directory names on the file system.
/// So if you want to change this method, be sure to guarantee compatibility with existing table data.
String MergeTreePartition::getID(const Block & partition_key_sample) const
@ -87,6 +90,8 @@ String MergeTreePartition::getID(const Block & partition_key_sample) const
return result;
}
#pragma GCC diagnostic pop
void MergeTreePartition::serializeText(const MergeTreeData & storage, WriteBuffer & out, const FormatSettings & format_settings) const
{
auto metadata_snapshot = storage.getInMemoryMetadataPtr();