It is in principle possible that blkhash_free() (which obviously frees
a struct blktab, sigh) is called with NULL. This would lead to a crash.
ok claudio
-/* $OpenBSD: blocks.c,v 1.26 2024/09/27 13:10:39 tb Exp $ */
+/* $OpenBSD: blocks.c,v 1.27 2024/09/27 13:13:14 tb Exp $ */
/*
* Copyright (c) 2019 Kristaps Dzonsons <kristaps@bsd.lv>
*
void
blkhash_free(struct blktab *p)
{
+ if (p == NULL)
+ return;
free(p->q);
free(p->blks);
free(p);