Skip to content

Commit f3cebfb

Browse files
committed
Fix system table path factory ownership
1 parent 85b0fa7 commit f3cebfb

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/paimon/core/table/system/metadata_system_tables.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -207,14 +207,14 @@ Result<std::shared_ptr<FileStorePathFactory>> CreatePathFactory(
207207
PAIMON_ASSIGN_OR_RAISE(std::optional<std::string> global_index_external_path,
208208
core_options.CreateGlobalIndexExternalPath());
209209
PAIMON_ASSIGN_OR_RAISE(
210-
std::unique_ptr<FileStorePathFactory> path_factory,
210+
std::shared_ptr<FileStorePathFactory> path_factory,
211211
FileStorePathFactory::Create(
212212
context.table_path, arrow_schema, context.table_schema->PartitionKeys(),
213213
core_options.GetPartitionDefaultName(), core_options.GetFileFormat()->Identifier(),
214214
core_options.DataFilePrefix(), core_options.LegacyPartitionNameEnabled(),
215215
external_paths, global_index_external_path, core_options.IndexFileInDataFileDir(),
216216
pool));
217-
return std::shared_ptr<FileStorePathFactory>(std::move(path_factory));
217+
return path_factory;
218218
}
219219

220220
Result<std::optional<Snapshot>> LatestSnapshot(const MetadataSystemTableContext& context) {

0 commit comments

Comments
 (0)