core: fix size used in snprintf when reading a configuration file