From 8f2e4bb8c97015680adfe1a7ebac377b0fa323db Mon Sep 17 00:00:00 2001 From: zhushengle Date: Mon, 19 Apr 2021 21:28:04 +0800 Subject: [PATCH] IssueNo:#I3H7TO fix:the setitimer signals the process to be locked at a fixed time. There is a static problem. Change-Id: I26f12289c4b13b0fd70bf0aad30507270e0ee421 --- compat/posix/src/time.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/compat/posix/src/time.c b/compat/posix/src/time.c index 538a2bf3..e001336b 100755 --- a/compat/posix/src/time.c +++ b/compat/posix/src/time.c @@ -586,6 +586,7 @@ typedef struct { static VOID SwtmrProc(UINTPTR tmrArg) { + unsigned int intSave; int sig; pid_t pid; siginfo_t info; @@ -610,7 +611,10 @@ static VOID SwtmrProc(UINTPTR tmrArg) info.si_value.sival_ptr = arg->sigev_value.sival_ptr; /* Send the signal */ + SCHEDULER_LOCK(intSave); OsDispatch(pid, &info, OS_USER_KILL_PERMISSION); + SCHEDULER_UNLOCK(intSave); + return; } -- GitLab