Separate out settings validation to settings.c, also print all errors before existing

Signed-off-by: Mattias Andrée <maandree@operamail.com>