RTEMS | flashdisk.c: Fixed garbage name generation and added memory cleanup (!912)

Prakhar Kumar (@prakhar) gitlab at rtems.org
Thu Jan 15 14:56:28 UTC 2026



Prakhar Kumar created a merge request: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/912

Project:Branches: prakhar/rtems:flashdisk_initialize_fix to rtems/rtos/rtems:main
Author:   Prakhar Kumar




## Summary

The flashdisk initialize function modified the character at the position returned by sizeof(RTEMS_FLASHDISK_DEVICE_BASE_NAME), which points past the intended device suffix and results in undefined behavior. 

Adjust the index to update the suffix character directly, ensuring correct device names (fdda, fddb, ...) and also added memory cleanup

<!--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/912
You're receiving this email because of your account on gitlab.rtems.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20260115/aafa1e3b/attachment.htm>


More information about the bugs mailing list