many: more checks for pointer access without NULL check (#41370)

This is a followup for https://github.com/systemd/systemd/pull/41096
that makes more subsystems pass the new `check-pointer-deref` coccinelle
checks. See the individual commits.

My plan is to do a few more of these PRs until we have it all covered. I
could also do it in a single very big PR but I'm worried about a)
conflicts b) that its just too big/annoying to review. Only 7 dirs left
but some (like src/basic) are quite big (~50k loc) so those PRs will be
a bit bigger.
This commit is contained in:
Zbigniew Jędrzejewski-Szmek
2026-03-27 14:58:27 +01:00
committed by GitHub
24 changed files with 58 additions and 11 deletions
-1
View File
@@ -74,7 +74,6 @@ EFI_STATUS initrd_register(
EFI_HANDLE handle;
struct initrd_loader *loader;
POINTER_MAY_BE_NULL(initrd);
assert(ret_initrd_handle);
/* If no initrd is specified we'll not install any. This avoids registration of the protocol for that