mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-10-04 20:59:21 +02:00
g_unix_set_fd_nonblocking: New API to control file descriptor blocking state
And use it in relevant places in GLib. https://bugzilla.gnome.org/show_bug.cgi?id=649225
This commit is contained in:
@@ -4638,7 +4638,7 @@ init_unix_signal_wakeup_state_unlocked (void)
|
||||
|
||||
if (!g_unix_pipe_flags (unix_signal_wake_up_pipe, FD_CLOEXEC, &error))
|
||||
g_error ("Cannot create UNIX signal wake up pipe: %s\n", error->message);
|
||||
fcntl (unix_signal_wake_up_pipe[1], F_SETFL, O_NONBLOCK | fcntl (unix_signal_wake_up_pipe[1], F_GETFL));
|
||||
g_unix_set_fd_nonblocking (unix_signal_wake_up_pipe[1], TRUE, NULL);
|
||||
|
||||
/* We create a helper thread that polls on the wakeup pipe indefinitely */
|
||||
if (g_thread_create (unix_signal_helper_thread, NULL, FALSE, &error) == NULL)
|
||||
|
Reference in New Issue
Block a user