mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-28 10:31:57 +00:00
Fix unitialized memory
This commit is contained in:
parent
751319d0ef
commit
08f5ed6da3
@ -89,7 +89,8 @@ String MergeTreePartition::getID(const Block & partition_key_sample) const
|
|||||||
|
|
||||||
void MergeTreePartition::serializeText(const MergeTreeData & storage, WriteBuffer & out, const FormatSettings & format_settings) const
|
void MergeTreePartition::serializeText(const MergeTreeData & storage, WriteBuffer & out, const FormatSettings & format_settings) const
|
||||||
{
|
{
|
||||||
const auto & partition_key_sample = storage.getInMemoryMetadataPtr()->getPartitionKey().sample_block;
|
auto metadata_snapshot = storage.getInMemoryMetadataPtr();
|
||||||
|
const auto & partition_key_sample = metadata_snapshot->getPartitionKey().sample_block;
|
||||||
size_t key_size = partition_key_sample.columns();
|
size_t key_size = partition_key_sample.columns();
|
||||||
|
|
||||||
if (key_size == 0)
|
if (key_size == 0)
|
||||||
|
Loading…
Reference in New Issue
Block a user