"GOT", but the "O" is a cute, smiling pufferfish. Index | Thread | Search

From:
Stefan Sperling <stsp@stsp.name>
Subject:
Re: gotd: allow repository directives in global scope
To:
Martijn van Duren <openbsd+got@list.imperialat.at>, gameoftrees@openbsd.org
Date:
Sat, 4 Nov 2023 11:45:35 +0100

Download raw body.

Thread
On Sat, Nov 04, 2023 at 11:33:13AM +0100, Stefan Sperling wrote:
> static int
> repo_has_protected_refs(struct gotd_repo *repo)
> {
>   return (TAILQ_EMPTY(&repo->protected_tag_namespaces) &&
>       TAILQ_EMPTY(&repo->protected_branch_namespaces) &&
>       TAILQ_EMPTY(&repo->protected_branches));
> }

Oops, careful I forgot a ! in front of this check.
Or we could rename the function to repo_has_no_protected_refs.