From: Joachim Kuebart Date: Tue, 9 Mar 2021 12:48:19 +0000 (+0100) Subject: fix: keep going when forms have only hidden fields X-Git-Tag: v8.20~356^2~2 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=3775544af5da4cfe7a1488c9d74e894afed1b53e;p=users%2Fdwmw2%2Fopenconnect.git fix: keep going when forms have only hidden fields Don't consider forms with hidden fields empty. Signed-off-by: Joachim Kuebart --- diff --git a/main.c b/main.c index 31bd5c1d..6a7e2436 100644 --- a/main.c +++ b/main.c @@ -2548,7 +2548,8 @@ static int process_auth_form_cb(void *_vpninfo, if (!opt->_value) goto err; empty = 0; - } else if (opt->type == OC_FORM_OPT_TOKEN) { + } else if (opt->type == OC_FORM_OPT_TOKEN || + opt->type == OC_FORM_OPT_HIDDEN) { /* Nothing to do here, but if the tokencode is being * automatically generated then don't treat it as an * empty form for the purpose of loop avoidance. */