Kernel/LibC: Implement SA_RESTART

I have been thinking how to do this for a long time but I finally
figured out a semi-clean way
This commit is contained in:
2025-04-22 02:42:44 +03:00
parent 34e680d792
commit 808c97020a
6 changed files with 16 additions and 7 deletions

View File

@@ -53,7 +53,8 @@ namespace Kernel
// Returns true if pending signal can be added to thread
bool can_add_signal_to_execute() const;
bool will_execute_signal() const;
void handle_signal(int signal = 0);
// Returns true if handled signal had SA_RESTART
bool handle_signal(int signal = 0);
bool add_signal(int signal);
// blocks current thread and returns either on unblock, eintr, spuriously or after timeout