This is an automated email from the ASF dual-hosted git repository.

xiaoxiang781216 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx.git

commit 315d9f7e64a26149ba4da133330d58bfc0d68c46
Author: DuoYuWang <[email protected]>
AuthorDate: Thu Aug 27 20:53:03 2026 +0800

    libc/wqueue: use the uninterruptible wait helper
    
    Replace the local EINTR retry loop with nxsem_wait_uninterruptible().
    This keeps the master implementation aligned with the libc semaphore API
    without changing cancellation behavior.
    
    Keep the cleanup separate so release branches where the helper is not
    available to Protected user space can use the functional commit without a
    downstream compatibility patch.
    
    Assisted-by: Codex:GPT-5
    Signed-off-by: DuoYuWang <[email protected]>
---
 libs/libc/wqueue/work_cancel.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/libs/libc/wqueue/work_cancel.c b/libs/libc/wqueue/work_cancel.c
index cd23c783204..65893daae31 100644
--- a/libs/libc/wqueue/work_cancel.c
+++ b/libs/libc/wqueue/work_cancel.c
@@ -125,11 +125,7 @@ static int work_qcancel(FAR struct usr_wqueue_s *wqueue, 
bool sync,
           return OK;
         }
 
-      do
-        {
-          ret = nxsem_wait(sync_wait);
-        }
-      while (ret == -EINTR);
+      nxsem_wait_uninterruptible(sync_wait);
     }
 }
 

Reply via email to