Deprecated rak::path_expand.

This commit is contained in:
Jari Sundell
2026-01-08 15:27:53 +01:00
committed by GitHub
parent 289ab046bf
commit b233e24465
21 changed files with 72 additions and 325 deletions
+5 -4
View File
@@ -1,10 +1,11 @@
#include "config.h"
#include <rak/path.h>
#include "utils/file_status_cache.h"
#include <torrent/exceptions.h>
#include <torrent/utils/file_stat.h>
#include "file_status_cache.h"
#include "globals.h"
namespace utils {
@@ -15,7 +16,7 @@ FileStatusCache::insert(const std::string& path) {
// Should we expand somewhere else? Problem is it adds a lot of junk
// to the start of the paths added to the cache, causing more work
// during search, etc.
if (!fs.update(rak::path_expand(path)))
if (!fs.update(expand_path(path)))
return false;
std::pair<iterator, bool> result = base_type::insert(value_type(path, file_status()));
@@ -40,7 +41,7 @@ FileStatusCache::prune() {
torrent::utils::FileStat fs;
iterator tmp = itr++;
if (!fs.update(rak::path_expand(tmp->first)) || tmp->second.m_mtime != (uint32_t)fs.modified_time())
if (!fs.update(expand_path(tmp->first)) || tmp->second.m_mtime != (uint32_t)fs.modified_time())
base_type::erase(tmp);
}
}