From fba47dc0eafc168ddc42e08850244b5603d02132 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Fri, 3 Oct 2008 12:42:13 +0000 Subject: Modified format library. parse_configfile2, update_configfile2, get_section, and set_section became parse_ini_file, update_ini_file, get_ini_section, and set_ini_section. Updated all code that used these functions. git-svn-id: svn://svn.alpinelinux.org/acf/openntpd/trunk@1539 ab2d0c66-481e-0410-8bed-d214d4d58bed --- openntpd-model.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/openntpd-model.lua b/openntpd-model.lua index 52bffd3..42f17e4 100644 --- a/openntpd-model.lua +++ b/openntpd-model.lua @@ -83,7 +83,7 @@ function read_config () end end - local opts = string.sub(format.parse_configfile2(fs.read_file(confdfile), "", "NTPD_OPTS"), 2, -2) + local opts = string.sub(format.parse_ini_file(fs.read_file(confdfile), "", "NTPD_OPTS"), 2, -2) if format.opts_to_table(opts, "-s") then config.setstimeonstartup.value = true end @@ -138,7 +138,7 @@ function update_config(config) -- Finally, handle setstimeonstartup local opts = {} if config.value.setstimeonstartup.value then opts["-s"] = "" end - fs.write_file(confdfile, format.update_configfile2(fs.read_file(confdfile) or "", "", "NTPD_OPTS", '"'..format.table_to_opts(opts)..'"')) + fs.write_file(confdfile, format.update_ini_file(fs.read_file(confdfile) or "", "", "NTPD_OPTS", '"'..format.table_to_opts(opts)..'"')) else config.errtxt = "Failed to save config" end -- cgit v1.2.3