MITHILESH MATTAPALLI created a merge request: 
https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/905

Project:Branches: mithileshm/rtems:fix-nvdisk-leak to rtems/rtos/rtems:main
Author:   MITHILESH MATTAPALLI




## Summary

cpukit/libblock: Fix resource leak in rtems_nvdisk_initialize (CID 1439297)

The function allocates memory for the nvd array but iterates the pointer
during initialization. If subsequent allocations fail, the function
returns without freeing the original allocated memory.

This patch saves the base pointer nvd_start and ensures it is freed
in error handling paths.

CID 1439297


<!-- Default settings, if it is a dropdown it will set after submission -->

-- 
View it on GitLab: 
https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/905
You're receiving this email because of your account on gitlab.rtems.org.


_______________________________________________
bugs mailing list
[email protected]
http://lists.rtems.org/mailman/listinfo/bugs

Reply via email to