Changeset View
Changeset View
Standalone View
Standalone View
src/index/base.cpp
Show All 17 Lines | |||||
#include <functional> | #include <functional> | ||||
constexpr char DB_BEST_BLOCK = 'B'; | constexpr char DB_BEST_BLOCK = 'B'; | ||||
constexpr int64_t SYNC_LOG_INTERVAL = 30; // seconds | constexpr int64_t SYNC_LOG_INTERVAL = 30; // seconds | ||||
constexpr int64_t SYNC_LOCATOR_WRITE_INTERVAL = 30; // seconds | constexpr int64_t SYNC_LOCATOR_WRITE_INTERVAL = 30; // seconds | ||||
template <typename... Args> | template <typename... Args> | ||||
static void FatalError(const char *fmt, const Args &... args) { | static void FatalError(const char *fmt, const Args &...args) { | ||||
std::string strMessage = tfm::format(fmt, args...); | std::string strMessage = tfm::format(fmt, args...); | ||||
SetMiscWarning(Untranslated(strMessage)); | SetMiscWarning(Untranslated(strMessage)); | ||||
LogPrintf("*** %s\n", strMessage); | LogPrintf("*** %s\n", strMessage); | ||||
AbortError(_("A fatal internal error occurred, see debug.log for details")); | AbortError(_("A fatal internal error occurred, see debug.log for details")); | ||||
StartShutdown(); | StartShutdown(); | ||||
} | } | ||||
BaseIndex::DB::DB(const fs::path &path, size_t n_cache_size, bool f_memory, | BaseIndex::DB::DB(const fs::path &path, size_t n_cache_size, bool f_memory, | ||||
▲ Show 20 Lines • Show All 303 Lines • Show Last 20 Lines |