commit fa7014189021ca34283ee2283918646f21b26f9b from: Stefan Sperling date: Mon Jan 02 12:02:56 2023 UTC gotd.conf: treat repositories without any parameters as a syntax error Because gotd expects some parameters to be present they must not be optional at the syntax level. commit - 05791aa0b360dbff2a5212ef7babf4f96caf3940 commit + fa7014189021ca34283ee2283918646f21b26f9b blob - 64e720e2de27b8b2d1a4ab147d28cdac86cd6db0 blob + 600804ea94852ce949195c67cd44ea59c6bc7d92 --- gotd/parse.y +++ gotd/parse.y @@ -187,23 +187,6 @@ repository : REPOSITORY STRING { new_repo = conf_new_repo($2); } free($2); - } - | REPOSITORY STRING { - struct gotd_repo *repo; - - TAILQ_FOREACH(repo, &gotd->repos, entry) { - if (strcmp(repo->name, $2) == 0) { - yyerror("duplicate repository '%s'", $2); - free($2); - YYERROR; - } - } - - if (gotd_proc_id == PROC_GOTD || - gotd_proc_id == PROC_AUTH) { - new_repo = conf_new_repo($2); - } - free($2); } '{' optnl repoopts2 '}' { } ;