RTEMS | Draft: libmisc/regulator: Fix assertion failures and resource leaks on error paths (!1479)
Sharvin Neve (@Sharvin)
gitlab at rtems.org
Wed Sep 9 15:30:43 UTC 2026
Sharvin Neve commented: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1479#note_158934
Hi Sebastian,
Thank you for the review and guidance. I have updated the branch and split the work into two commits as requested:
1. `cpukit/libmisc: Accept an empty regulator queue` (`Update #5747.`):
- Updates the dequeue assertion to accept `RTEMS_UNSATISFIED`.
2. `cpukit/libmisc: Clean up a partial regulator` (`Close #5747.`, `Close #5760.`):
- Uses `#define REGULATOR_NO_ID ( (rtems_id) UINT32_MAX )` for task, queue, and partition identifiers.
- Deletes the period and sets `delivery_thread_has_exited = true` before assigning `delivery_thread_is_running = false` on the exit path.
- Retains the period deletion in `_Regulator_Free_helper()` when deleting the task.
- Frees `message_queue_storage` directly if queue construction fails.
- Drops redundant stores into the instance prior to `free()`.
Both commits are rebased on the latest `master`. Ready for final review.
--
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1479#note_158934
You're receiving this email because of your account on gitlab.rtems.org. Unsubscribe from this thread: https://gitlab.rtems.org/-/sent_notifications/5-extuuyvanqv4kyt4dobzu0j9g-1d/unsubscribe | Manage all notifications: https://gitlab.rtems.org/-/profile/notifications | Help: https://gitlab.rtems.org/help
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20260909/4341cb35/attachment.htm>
More information about the bugs
mailing list