mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-09-29 21:20:49 +00:00
Cleanup destination directory during DiskCacheWrapper::moveFile()
This commit is contained in:
parent
e6711e936e
commit
7c0a1b9451
@ -217,7 +217,7 @@ void DiskCacheWrapper::moveFile(const String & from_path, const String & to_path
|
||||
{
|
||||
if (cache_disk->exists(from_path))
|
||||
{
|
||||
if (cache_disk->isDirectory(to_path) && !cache_disk->isDirectoryEmpty(to_path))
|
||||
if (cache_disk->exists(to_path) && cache_disk->isDirectory(to_path))
|
||||
cache_disk->clearDirectory(to_path);
|
||||
|
||||
auto dir_path = directoryPath(to_path);
|
||||
|
Loading…
Reference in New Issue
Block a user