diff --git a/src/system/runtime_loader/elf.cpp b/src/system/runtime_loader/elf.cpp index 02e8c547e8..819fbe9ac6 100644 --- a/src/system/runtime_loader/elf.cpp +++ b/src/system/runtime_loader/elf.cpp @@ -370,6 +370,9 @@ delete_image_struct(image_t *image) static void delete_image(image_t *image) { + if (image == NULL) + return; + _kern_unregister_image(image->id); // registered in load_container()