浏览代码

Create the catalog's parent dir before opening

default_compile_flags
vector-of-bool 5 年前
父节点
当前提交
c74b73cfcb
共有 1 个文件被更改,包括 3 次插入0 次删除
  1. +3
    -0
      src/dds/catalog/catalog.cpp

+ 3
- 0
src/dds/catalog/catalog.cpp 查看文件

@@ -92,6 +92,9 @@ void ensure_migrated(sqlite3::database& db) {
} // namespace

catalog catalog::open(const std::string& db_path) {
if (db_path != ":memory:") {
fs::create_directories(fs::weakly_canonical(db_path).parent_path());
}
auto db = sqlite3::database::open(db_path);
try {
ensure_migrated(db);

正在加载...
取消
保存