]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
import: fix NULL pointer dereference
authorYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 20 Feb 2026 07:11:50 +0000 (16:11 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 20 Feb 2026 07:12:36 +0000 (16:12 +0900)
Follow-up for a9f6ba04969d6eb2e629e30299fab7538ef42a57.
Fixes CID#1645106.

src/import/pull-oci.c

index 39b9c6e76825e58ab07ad7b527252b0fff6e0d91..6ab58eb1ac0e4dd206c2884758b9456043ec6813 100644 (file)
@@ -101,7 +101,10 @@ static OciLayerState* oci_layer_state_free(OciLayerState *st) {
         pidref_done_sigkill_wait(&st->tar_pid);
 
         if (st->temp_path) {
-                import_remove_tree(st->temp_path, st->pull ? &st->pull->userns_fd : NULL, st->pull->flags);
+                import_remove_tree(
+                                st->temp_path,
+                                st->pull ? &st->pull->userns_fd : NULL,
+                                st->pull ? st->pull->flags : 0);
                 free(st->temp_path);
         }
         free(st->final_path);