From d4c98c35e23d6a6828f0e18c9268b0542b907891 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Mon, 29 Sep 2008 18:01:28 +0000 Subject: Removed getopts library and added functionality to format library as opts_to_table, table_to_opts, parse_configfile2, update_configfile2, get_section, and set_section. New functions work on strings, not files. Modified all code using getopts to use format instead. Fixed nil string bugs in TCPProxy. Fixed forward only bug in DNSCache. git-svn-id: svn://svn.alpinelinux.org/acf/gnats/trunk@1535 ab2d0c66-481e-0410-8bed-d214d4d58bed --- gnats-model.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'gnats-model.lua') diff --git a/gnats-model.lua b/gnats-model.lua index ed07361..706ac55 100644 --- a/gnats-model.lua +++ b/gnats-model.lua @@ -3,7 +3,6 @@ module(..., package.seeall) -- Load libraries require("fs") require("date") -require("getopts") require("format") require("posix") require("validator") @@ -377,7 +376,7 @@ end function getconfig() if (fs.is_file(configfile)) then - return getopts.getoptsfromfile(configfile, "") or {} + return format.parse_configfile2(fs.read_file(configfile), "") or {} end return {} end -- cgit v1.2.3