diff options
| author | 2021-05-07 02:09:13 +1000 | |
|---|---|---|
| committer | 2021-05-07 02:14:05 +1000 | |
| commit | fab84e8d2b9177e11d334a82892dc554d128052b (patch) | |
| tree | b7cbeb727891f6c09048f1f11f9dbe9576e348fe /plugins/data | |
| parent | 075d934ff422e6b03352d91877d4ec92fb218641 (diff) | |
Mostly revert "Create console history file in homepath (#8026)"
The change to make the console plugin work is preserved.
This reverts commit 25137717c9392d142650fcd679b09c400a2f5c4a.
Diffstat (limited to 'plugins/data')
| -rw-r--r-- | plugins/data/data_hiscore.lua | 4 | ||||
| -rw-r--r-- | plugins/data/database.lua | 6 |
2 files changed, 2 insertions, 8 deletions
diff --git a/plugins/data/data_hiscore.lua b/plugins/data/data_hiscore.lua index e6d7d75fdc0..3bf5467fe9e 100644 --- a/plugins/data/data_hiscore.lua +++ b/plugins/data/data_hiscore.lua @@ -1,8 +1,6 @@ -- to use this get the package from http://greatstone.free.fr/hi2txt/ -- extract the hi2txt.zip and place it in your history path -local util = require("util") - local dat = {} local env = {} local output @@ -1208,7 +1206,7 @@ function dat.check(set, softlist) local scrpath = path:match("[^;]*") .. "/" local scrfile = io.open(scrpath .. set .. ".lua", "w+") if not scrfile then - util.mkdir_recursive(scrpath) + lfs.mkdir(scrpath) scrfile = io.open(scrpath .. set .. ".lua", "w+") end if scrfile then diff --git a/plugins/data/database.lua b/plugins/data/database.lua index bd7de2d665d..b868173ce08 100644 --- a/plugins/data/database.lua +++ b/plugins/data/database.lua @@ -1,7 +1,6 @@ local sql = require("lsqlite3") local datfile = {} local db -local util = require("util") local function check_db(msg) if db:errcode() > sql.OK then @@ -13,10 +12,7 @@ do local dbpath = emu.subst_env(mame_manager.ui.options.entries.historypath:value():match("([^;]+)")) db = sql.open(dbpath .. "/history.db") if not db then - local success, err = util.mkdir_recursive(dbpath) - if not success then - emu.print_error("Unable to create parent directories for history database: " .. err) - end + lfs.mkdir(dbpath) db = sql.open(dbpath .. "/history.db") if not db then emu.print_error("Unable to create history.db\n") |
