Fix config file parsing and newlines in mails