On Thu, May 15, 2025 at 12:45:27PM +0000, Johannes Schindelin via GitGitGadget wrote: > CodeQL points out that `lookup_commit_reference()` can return NULL > values. > [...] > commit = lookup_commit_reference(r, &oid); > - if (repo_parse_commit(r, commit)) > + if (!commit || repo_parse_commit(r, commit)) > return MISSING_OBJECT; Sure, but repo_parse_commit() can also handle NULL values. It returns "-1" in that case. I think CodeQL is not smart enough to know that. -Peff