From: Timo Sirainen Date: Tue, 14 Oct 2025 09:40:50 +0000 (+0300) Subject: lib-sasl: test-sasl-authentication - Avoid scan-build dead code complaint X-Git-Tag: 2.4.2~87 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=aca2dccadaeaba2a57d53ccde95ce9d876456c76;p=thirdparty%2Fdovecot%2Fcore.git lib-sasl: test-sasl-authentication - Avoid scan-build dead code complaint It wasn't really dead code, but test_assert() was marked as ATTR_NORETURN to static analyzer builds, so it looked like that. However, we can simply remove this check since test_assert(FALSE) causes the later failed || test_has_failed() check to match anyway. --- diff --git a/src/lib-sasl/test-sasl-authentication.c b/src/lib-sasl/test-sasl-authentication.c index e25e32b430..4af3e44132 100644 --- a/src/lib-sasl/test-sasl-authentication.c +++ b/src/lib-sasl/test-sasl-authentication.c @@ -283,7 +283,6 @@ test_server_request_output(struct sasl_server_req_ctx *rctx, switch (output->status) { case SASL_SERVER_OUTPUT_INTERNAL_FAILURE: e_debug(test_event, "Internal failure"); - failed = TRUE; test_assert(FALSE); tctx->finished = TRUE; break;