Yang Zhang created a merge request: 
https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1438

Project:Branches: Chloe/rtems:fix-dosfs-dangling-fs-info to 
rtems/rtos/rtems:main
Author:   Yang Zhang



## Summary

In msdos_initialize_support(), temp_mt_entry-\>fs_info was assigned the 
allocated fs_info structure before volume initialization. If subsequent steps 
failed (such as volume init, root directory open, or cluster buffer 
allocation), fs_info was freed, but temp_mt_entry-\>fs_info was left pointing 
to freed memory.

This created a dangling pointer in the mount table entry, which could lead to 
use-after-free or double-free errors during cleanup.

Fix this by delaying the assignment of temp_mt_entry-\>fs_info until all 
initialization steps have successfully completed.

## Generative AI

None

-- 
View it on GitLab: 
https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1438
You're receiving this email because of your account on gitlab.rtems.org. 
Unsubscribe from this thread: 
https://gitlab.rtems.org/-/sent_notifications/5-61nrb64160en9u11ki48wi819-1d/unsubscribe
 | Manage all notifications: https://gitlab.rtems.org/-/profile/notifications | 
Help: https://gitlab.rtems.org/help


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

Reply via email to