diff options
author | KatolaZ <katolaz@freaknet.org> | 2017-07-03 12:06:31 +0100 |
---|---|---|
committer | KatolaZ <katolaz@freaknet.org> | 2017-07-03 12:06:31 +0100 |
commit | dece484ef755746d7a212694cffae65e2eaee6b8 (patch) | |
tree | c832196914a1f6132fbe6be191d69ee8df7e2833 /config.go | |
parent | 4a9c3b4604b308a80984fddb9caf8b79fe553e97 (diff) |
Added a Makefile and log_file option to the config file0.1
Diffstat (limited to 'config.go')
-rw-r--r-- | config.go | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -41,8 +41,8 @@ type Config struct { bind_port string paste_dir string templ_dir string - log_fname string max_size uint16 + log_file string } @@ -54,8 +54,8 @@ func (c Config) String() string { s+= "Listening on: " + c.bind_addr + ":" + c.bind_port +"\n" s+= "paste_dir: " + c.paste_dir + "\n" s+= "templ_dir: " + c.templ_dir + "\n" - s+= "log_fname: " + c.log_fname + "\n" s+= "max_size: " + string(c.max_size) + "\n" + s+= "log_file: " + c.log_file + "\n" return s @@ -93,8 +93,8 @@ func parse_config (fname string, c *Config) error { c.paste_dir = strings.Trim(fields[1], " \t\"") case "templ_dir": c.templ_dir = strings.Trim(fields[1], " \t\"") - case "log_fname": - c.log_fname = strings.Trim(fields[1], " \t\"") + case "log_file": + c.log_file = strings.Trim(fields[1], " \t\"") case "max_size": if m_size, err := strconv.ParseUint(fields[1], 10, 16); err == nil { c.max_size = uint16(m_size) |