]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
shut up clang analyzer
authorAlan T. DeKok <aland@freeradius.org>
Tue, 31 Aug 2021 22:15:10 +0000 (18:15 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Tue, 31 Aug 2021 22:15:10 +0000 (18:15 -0400)
src/lib/util/machine.c

index 4bdb8652139d0b5c6242ddabd10af773bae003e9..aa6a2447bbb6f81cdbbb83ab8aeae79f6ff8150d 100644 (file)
@@ -234,6 +234,13 @@ fr_machine_t *fr_machine_alloc(TALLOC_CTX *ctx, fr_machine_def_t const *def, voi
        fr_assert(!m->current->def->exit);
        fr_assert(m->current->def->process);
 
+#if defined(__clang_analyzer__)
+       if (!m->current || !m->current->def || !m->current->def->process) {
+               talloc_free(m);
+               return NULL;
+       }
+#endif
+
        next = m->current->def->process(m, uctx);
        fr_assert(next >= 0);