dont try to use conffile count if libconfig is not present, fix #274

This commit is contained in:
yrutschle 2020-08-04 16:37:49 +02:00
parent e67d6ff905
commit 72438dc1ae

View File

@ -1,5 +1,5 @@
/* Generated by conf2struct (https://www.rutschle.net/tech/conf2struct/README)
* on Wed Jul 29 22:51:16 2020.
* on Tue Aug 4 16:36:09 2020.
# conf2struct: generate libconf parsers that read to structs
# Copyright (C) 2018-2019 Yves Rutschle
@ -1592,7 +1592,7 @@ int sslhcfg_cl_parse(int argc, char* argv[], struct sslhcfg_item* cfg)
config_init(&c);
if (sslhcfg_conffile->count) {
if (sslhcfg_conffile && sslhcfg_conffile->count) {
if (!c2s_parse_file(sslhcfg_conffile->filename[0], &c, &errmsg)) {
fprintf(stderr, "%s\n", errmsg);
return -1;