Open wucke13 opened 6 days ago
Thanks for raising this issue, @wucke13.
Looking at the code, I think the comment should read:
Simply convert the condition variable control block into a semaphore pointer.
What do you think?
The comment can be refined as following:
--- a/utility/rtos_compatibility_layers/posix/px_cond_signal.c
+++ b/utility/rtos_compatibility_layers/posix/px_cond_signal.c
@@ -89,7 +89,7 @@ TX_SEMAPHORE *semaphore_ptr;
UINT status;
/* Get the condition variable's internal semaphore. */
- /* Simply convert the COndition variable control block into a semaphore a cast */
+ /* Simply convert the condition variable control block into a semaphore using casting */
semaphore_ptr = (&( cond->cond_semaphore ));
if ( semaphore_ptr->tx_semaphore_suspended_count)
{
Seems sensible to me!
https://github.com/eclipse-threadx/threadx/blob/485a02faec6edccef14812ddce6844af1d7d2eef/utility/rtos_compatibility_layers/posix/px_cond_signal.c#L92