# French translation of manpages
# This file is distributed under the same license as the manpages-l10n package.
# Copyright © of this file:
# Christophe Blaess , 1996-2003.
# Stéphan Rafin , 2002.
# Thierry Vignaud , 1999, 2002.
# François Micaux, 2002.
# Alain Portal , 2003-2008.
# Jean-Philippe Guérard , 2005-2006.
# Jean-Luc Coulon (f5ibh) , 2006-2007.
# Julien Cristau , 2006-2007.
# Thomas Huriaux , 2006-2008.
# Nicolas François , 2006-2008.
# Florentin Duneau , 2006-2010.
# Simon Paillard , 2006.
# Denis Barbier , 2006, 2010.
# David Prévot , 2010, 2012.
# Frédéric Hantrais , 2013, 2014.
# Jean-Pierre Giraud , 2023-2024.
msgid ""
msgstr ""
"Project-Id-Version: manpages-l10n 4.22.0\n"
"POT-Creation-Date: 2026-06-05 06:38+0200\n"
"PO-Revision-Date: 2024-04-22 12:19+0200\n"
"Last-Translator: Jean-Pierre Giraud \n"
"Language-Team: French \n"
"Language: fr\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
"X-Generator: Lokalize 22.12.3\n"
#. type: TH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "pthread_sigmask"
msgstr "pthread_sigmask"
#. type: TH
#: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
#: opensuse-tumbleweed
#, no-wrap
msgid "2025-09-21"
msgstr "21 septembre 2025"
#. type: TH
#: archlinux debian-unstable
#, no-wrap
msgid "Linux man-pages 6.18"
msgstr "Pages du manuel de Linux 6.18"
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "NAME"
msgstr "NOM"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid "pthread_sigmask - examine and change mask of blocked signals"
msgstr "pthread_sigmask - Examiner et modifier le masque des signaux bloqués"
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "LIBRARY"
msgstr "BIBLIOTHÈQUE"
#. type: Plain text
#: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
#: opensuse-leap-16-1 opensuse-tumbleweed
msgid "POSIX threads library (I,\\ I<-lpthread>)"
msgstr "Bibliothèque de threads POSIX (I,\\ I<-lpthread>)"
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "SYNOPSIS"
msgstr "SYNOPSIS"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "B<#include Esignal.hE>\n"
msgstr "B<#include Esignal.hE>\n"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "BIB<, const sigset_t *>IB<, sigset_t *>IB<);>\n"
msgstr "BIB<, const sigset_t *>IB<, sigset_t *>IB<);>\n"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid ""
"Feature Test Macro Requirements for glibc (see B(7)):"
msgstr ""
"Exigences de macros de test de fonctionnalités pour la glibc (consulter "
"B(7)) :"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid "B():"
msgstr "B() :"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid " _POSIX_C_SOURCE E= 199506L || _XOPEN_SOURCE E= 500\n"
msgstr " _POSIX_C_SOURCE E= 199506L || _XOPEN_SOURCE E= 500\n"
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "DESCRIPTION"
msgstr "DESCRIPTION"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid ""
"The B() function is just like B(2), with the "
"difference that its use in multithreaded programs is explicitly specified by "
"POSIX.1. Other differences are noted in this page."
msgstr ""
"La fonction B() est identique à B(2), à la "
"différence près que son utilisation dans des programmes multithread est "
"explicitement spécifié dans POSIX.1. D'autres différences sont indiquées "
"dans cette page."
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid ""
"For a description of the arguments and operation of this function, see "
"B(2)."
msgstr ""
"Pour une description des arguments et du mode d'opération de cette fonction, "
"consultez B(2)."
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "RETURN VALUE"
msgstr "VALEUR RENVOYÉE"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid ""
"On success, B() returns 0; on error, it returns an error "
"number."
msgstr ""
"En cas de réussite, B() renvoie 0 ; en cas d'erreur, elle "
"renvoie un numéro d'erreur."
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "ERRORS"
msgstr "ERREURS"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid "See B(2)."
msgstr "Consultez B(2)."
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "ATTRIBUTES"
msgstr "ATTRIBUTS"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid ""
"For an explanation of the terms used in this section, see B(7)."
msgstr ""
"Pour une explication des termes utilisés dans cette section, consulter "
"B(7)."
#. type: tbl table
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "Interface"
msgstr "Interface"
#. type: tbl table
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "Attribute"
msgstr "Attribut"
#. type: tbl table
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "Value"
msgstr "Valeur"
#. type: tbl table
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid ".na\n"
msgstr ".na\n"
#. type: tbl table
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid ".nh\n"
msgstr ".nh\n"
#. type: tbl table
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "B()"
msgstr "B()"
#. type: tbl table
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "Thread safety"
msgstr "Sécurité des threads"
#. type: tbl table
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "MT-Safe"
msgstr "MT-Safe"
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "STANDARDS"
msgstr "NORMES"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid "POSIX.1-2008."
msgstr "POSIX.1-2008."
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "HISTORY"
msgstr "HISTORIQUE"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid "POSIX.1-2001."
msgstr "POSIX.1-2001."
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "NOTES"
msgstr "NOTES"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid "A new thread inherits a copy of its creator's signal mask."
msgstr ""
"Un nouveau thread hérite d'une copie du masque de signaux de son créateur."
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid ""
"The glibc B() function silently ignores attempts to block "
"the two real-time signals that are used internally by the NPTL threading "
"implementation. See B(7) for details."
msgstr ""
"La fonction B() de la glibc ignore silencieusement les "
"tentatives de blocage des deux signaux en temps réel qui sont utilisés en "
"interne par l'implémentation de threading de NPTL. Consultez B(7) pour "
"des détails."
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "EXAMPLES"
msgstr "EXEMPLES"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid ""
"The program below blocks some signals in the main thread, and then creates a "
"dedicated thread to fetch those signals via B(3). The following "
"shell session demonstrates its use:"
msgstr ""
"Le programme ci-dessous bloque certains signaux dans le thread principal, "
"puis crée un thread dédié pour récupérer ces signaux avec B(3). La "
"session d'interpréteur de commande ci-dessous démontre l'utilisation du "
"programme."
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid ""
"$B< ./a.out &>\n"
"[1] 5423\n"
"$B< kill -QUIT %1>\n"
"Signal handling thread got signal 3\n"
"$B< kill -USR1 %1>\n"
"Signal handling thread got signal 10\n"
"$B< kill -TERM %1>\n"
"[1]+ Terminated ./a.out\n"
msgstr ""
"$B< ./a.out &>\n"
"[1] 5423\n"
"$B< kill -QUIT %1>\n"
"Signal handling thread got signal 3\n"
"$B< kill -USR1 %1>\n"
"Signal handling thread got signal 10\n"
"$B< kill -TERM %1>\n"
"[1]+ Terminated ./a.out\n"
#. type: SS
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "Program source"
msgstr "Source du programme"
#. type: Plain text
#: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
#: opensuse-tumbleweed
#, fuzzy, no-wrap
#| msgid ""
#| "#include Eerrno.hE\n"
#| "#include Epthread.hE\n"
#| "#include Esignal.hE\n"
#| "#include Estdio.hE\n"
#| "#include Estdlib.hE\n"
#| "#include Eunistd.hE\n"
#| "\\&\n"
#| "/* Simple error handling functions */\n"
#| "\\&\n"
#| "#define handle_error_en(en, msg) \\e\n"
#| " do { errno = en; perror(msg); exit(EXIT_FAILURE); } while (0)\n"
#| "\\&\n"
#| "static void *\n"
#| "sig_thread(void *arg)\n"
#| "{\n"
#| " sigset_t *set = arg;\n"
#| " int s, sig;\n"
#| "\\&\n"
#| " for (;;) {\n"
#| " s = sigwait(set, &sig);\n"
#| " if (s != 0)\n"
#| " handle_error_en(s, \"sigwait\");\n"
#| " printf(\"Signal handling thread got signal %d\\en\", sig);\n"
#| " }\n"
#| "}\n"
#| "\\&\n"
#| "int\n"
#| "main(void)\n"
#| "{\n"
#| " pthread_t thread;\n"
#| " sigset_t set;\n"
#| " int s;\n"
#| "\\&\n"
#| " /* Block SIGQUIT and SIGUSR1; other threads created by main()\n"
#| " will inherit a copy of the signal mask. */\n"
#| "\\&\n"
#| " sigemptyset(&set);\n"
#| " sigaddset(&set, SIGQUIT);\n"
#| " sigaddset(&set, SIGUSR1);\n"
#| " s = pthread_sigmask(SIG_BLOCK, &set, NULL);\n"
#| " if (s != 0)\n"
#| " handle_error_en(s, \"pthread_sigmask\");\n"
#| "\\&\n"
#| " s = pthread_create(&thread, NULL, &sig_thread, &set);\n"
#| " if (s != 0)\n"
#| " handle_error_en(s, \"pthread_create\");\n"
#| "\\&\n"
#| " /* Main thread carries on to create other threads and/or do\n"
#| " other work. */\n"
#| "\\&\n"
#| " pause(); /* Dummy pause so we can test program */\n"
#| "}\n"
msgid ""
"#include Eerr.hE\n"
"#include Eerrno.hE\n"
"#include Epthread.hE\n"
"#include Esignal.hE\n"
"#include Estdio.hE\n"
"#include Estdlib.hE\n"
"#include Eunistd.hE\n"
"\\&\n"
"/* Simple error handling functions */\n"
"\\&\n"
"static void *\n"
"sig_thread(void *arg)\n"
"{\n"
" sigset_t *set = arg;\n"
" int s, sig;\n"
"\\&\n"
" for (;;) {\n"
" s = sigwait(set, &sig);\n"
" if (s != 0)\n"
" errc(EXIT_FAILURE, s, \"sigwait\");\n"
" printf(\"Signal handling thread got signal %d\\[rs]n\", sig);\n"
" }\n"
"}\n"
"\\&\n"
"int\n"
"main(void)\n"
"{\n"
" pthread_t thread;\n"
" sigset_t set;\n"
" int s;\n"
"\\&\n"
" /* Block SIGQUIT and SIGUSR1; other threads created by main()\n"
" will inherit a copy of the signal mask. */\n"
"\\&\n"
" sigemptyset(&set);\n"
" sigaddset(&set, SIGQUIT);\n"
" sigaddset(&set, SIGUSR1);\n"
" s = pthread_sigmask(SIG_BLOCK, &set, NULL);\n"
" if (s != 0)\n"
" errc(EXIT_FAILURE, s, \"pthread_sigmask\");\n"
"\\&\n"
" s = pthread_create(&thread, NULL, &sig_thread, &set);\n"
" if (s != 0)\n"
" errc(EXIT_FAILURE, s, \"pthread_create\");\n"
"\\&\n"
" /* Main thread carries on to create other threads and/or do\n"
" other work. */\n"
"\\&\n"
" pause(); /* Dummy pause so we can test program */\n"
"}\n"
msgstr ""
"#include Eerrno.hE\n"
"#include Epthread.hE\n"
"#include Esignal.hE\n"
"#include Estdio.hE\n"
"#include Estdlib.hE\n"
"#include Eunistd.hE\n"
"\\&\n"
"/* Simple error handling functions */\n"
"\\&\n"
"#define handle_error_en(en, msg) \\e\n"
" do { errno = en; perror(msg); exit(EXIT_FAILURE); } while (0)\n"
"\\&\n"
"static void *\n"
"sig_thread(void *arg)\n"
"{\n"
" sigset_t *set = arg;\n"
" int s, sig;\n"
"\\&\n"
" for (;;) {\n"
" s = sigwait(set, &sig);\n"
" if (s != 0)\n"
" handle_error_en(s, \"sigwait\");\n"
" printf(\"Signal handling thread got signal %d\\en\", sig);\n"
" }\n"
"}\n"
"\\&\n"
"int\n"
"main(void)\n"
"{\n"
" pthread_t thread;\n"
" sigset_t set;\n"
" int s;\n"
"\\&\n"
" /* Block SIGQUIT and SIGUSR1; other threads created by main()\n"
" will inherit a copy of the signal mask. */\n"
"\\&\n"
" sigemptyset(&set);\n"
" sigaddset(&set, SIGQUIT);\n"
" sigaddset(&set, SIGUSR1);\n"
" s = pthread_sigmask(SIG_BLOCK, &set, NULL);\n"
" if (s != 0)\n"
" handle_error_en(s, \"pthread_sigmask\");\n"
"\\&\n"
" s = pthread_create(&thread, NULL, &sig_thread, &set);\n"
" if (s != 0)\n"
" handle_error_en(s, \"pthread_create\");\n"
"\\&\n"
" /* Main thread carries on to create other threads and/or do\n"
" other work. */\n"
"\\&\n"
" pause(); /* Dummy pause so we can test program */\n"
"}\n"
#. SRC END
#. type: SH
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "SEE ALSO"
msgstr "VOIR AUSSI"
#. type: Plain text
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
msgid ""
"B(2), B(2), B(2), "
"B(3), B(3), B(3), "
"B(3), B(7), B(7)"
msgstr ""
"B(2), B(2), B(2), "
"B(3), B(3), B(3), "
"B(3), B(7), B(7)"
#. type: TH
#: debian-trixie
#, no-wrap
msgid "2024-06-15"
msgstr "15 juin 2024"
#. type: TH
#: debian-trixie
#, no-wrap
msgid "Linux man-pages 6.9.1"
msgstr "Pages du manuel de Linux 6.9.1"
#. type: Plain text
#: debian-trixie
msgid "POSIX threads library (I, I<-lpthread>)"
msgstr "Bibliothèque de threads POSIX (I, I<-lpthread>)"
#. type: Plain text
#: debian-trixie fedora-44 fedora-rawhide
#, fuzzy, no-wrap
#| msgid ""
#| "#include Eerrno.hE\n"
#| "#include Epthread.hE\n"
#| "#include Esignal.hE\n"
#| "#include Estdio.hE\n"
#| "#include Estdlib.hE\n"
#| "#include Eunistd.hE\n"
#| "\\&\n"
#| "/* Simple error handling functions */\n"
#| "\\&\n"
#| "#define handle_error_en(en, msg) \\e\n"
#| " do { errno = en; perror(msg); exit(EXIT_FAILURE); } while (0)\n"
#| "\\&\n"
#| "static void *\n"
#| "sig_thread(void *arg)\n"
#| "{\n"
#| " sigset_t *set = arg;\n"
#| " int s, sig;\n"
#| "\\&\n"
#| " for (;;) {\n"
#| " s = sigwait(set, &sig);\n"
#| " if (s != 0)\n"
#| " handle_error_en(s, \"sigwait\");\n"
#| " printf(\"Signal handling thread got signal %d\\en\", sig);\n"
#| " }\n"
#| "}\n"
#| "\\&\n"
#| "int\n"
#| "main(void)\n"
#| "{\n"
#| " pthread_t thread;\n"
#| " sigset_t set;\n"
#| " int s;\n"
#| "\\&\n"
#| " /* Block SIGQUIT and SIGUSR1; other threads created by main()\n"
#| " will inherit a copy of the signal mask. */\n"
#| "\\&\n"
#| " sigemptyset(&set);\n"
#| " sigaddset(&set, SIGQUIT);\n"
#| " sigaddset(&set, SIGUSR1);\n"
#| " s = pthread_sigmask(SIG_BLOCK, &set, NULL);\n"
#| " if (s != 0)\n"
#| " handle_error_en(s, \"pthread_sigmask\");\n"
#| "\\&\n"
#| " s = pthread_create(&thread, NULL, &sig_thread, &set);\n"
#| " if (s != 0)\n"
#| " handle_error_en(s, \"pthread_create\");\n"
#| "\\&\n"
#| " /* Main thread carries on to create other threads and/or do\n"
#| " other work. */\n"
#| "\\&\n"
#| " pause(); /* Dummy pause so we can test program */\n"
#| "}\n"
msgid ""
"#include Eerrno.hE\n"
"#include Epthread.hE\n"
"#include Esignal.hE\n"
"#include Estdio.hE\n"
"#include Estdlib.hE\n"
"#include Eunistd.hE\n"
"\\&\n"
"/* Simple error handling functions */\n"
"\\&\n"
"#define handle_error_en(en, msg) \\[rs]\n"
" do { errno = en; perror(msg); exit(EXIT_FAILURE); } while (0)\n"
"\\&\n"
"static void *\n"
"sig_thread(void *arg)\n"
"{\n"
" sigset_t *set = arg;\n"
" int s, sig;\n"
"\\&\n"
" for (;;) {\n"
" s = sigwait(set, &sig);\n"
" if (s != 0)\n"
" handle_error_en(s, \"sigwait\");\n"
" printf(\"Signal handling thread got signal %d\\[rs]n\", sig);\n"
" }\n"
"}\n"
"\\&\n"
"int\n"
"main(void)\n"
"{\n"
" pthread_t thread;\n"
" sigset_t set;\n"
" int s;\n"
"\\&\n"
" /* Block SIGQUIT and SIGUSR1; other threads created by main()\n"
" will inherit a copy of the signal mask. */\n"
"\\&\n"
" sigemptyset(&set);\n"
" sigaddset(&set, SIGQUIT);\n"
" sigaddset(&set, SIGUSR1);\n"
" s = pthread_sigmask(SIG_BLOCK, &set, NULL);\n"
" if (s != 0)\n"
" handle_error_en(s, \"pthread_sigmask\");\n"
"\\&\n"
" s = pthread_create(&thread, NULL, &sig_thread, &set);\n"
" if (s != 0)\n"
" handle_error_en(s, \"pthread_create\");\n"
"\\&\n"
" /* Main thread carries on to create other threads and/or do\n"
" other work. */\n"
"\\&\n"
" pause(); /* Dummy pause so we can test program */\n"
"}\n"
msgstr ""
"#include Eerrno.hE\n"
"#include Epthread.hE\n"
"#include Esignal.hE\n"
"#include Estdio.hE\n"
"#include Estdlib.hE\n"
"#include Eunistd.hE\n"
"\\&\n"
"/* Simple error handling functions */\n"
"\\&\n"
"#define handle_error_en(en, msg) \\e\n"
" do { errno = en; perror(msg); exit(EXIT_FAILURE); } while (0)\n"
"\\&\n"
"static void *\n"
"sig_thread(void *arg)\n"
"{\n"
" sigset_t *set = arg;\n"
" int s, sig;\n"
"\\&\n"
" for (;;) {\n"
" s = sigwait(set, &sig);\n"
" if (s != 0)\n"
" handle_error_en(s, \"sigwait\");\n"
" printf(\"Signal handling thread got signal %d\\en\", sig);\n"
" }\n"
"}\n"
"\\&\n"
"int\n"
"main(void)\n"
"{\n"
" pthread_t thread;\n"
" sigset_t set;\n"
" int s;\n"
"\\&\n"
" /* Block SIGQUIT and SIGUSR1; other threads created by main()\n"
" will inherit a copy of the signal mask. */\n"
"\\&\n"
" sigemptyset(&set);\n"
" sigaddset(&set, SIGQUIT);\n"
" sigaddset(&set, SIGUSR1);\n"
" s = pthread_sigmask(SIG_BLOCK, &set, NULL);\n"
" if (s != 0)\n"
" handle_error_en(s, \"pthread_sigmask\");\n"
"\\&\n"
" s = pthread_create(&thread, NULL, &sig_thread, &set);\n"
" if (s != 0)\n"
" handle_error_en(s, \"pthread_create\");\n"
"\\&\n"
" /* Main thread carries on to create other threads and/or do\n"
" other work. */\n"
"\\&\n"
" pause(); /* Dummy pause so we can test program */\n"
"}\n"
#. type: TH
#: fedora-44 fedora-rawhide
#, no-wrap
msgid "2024-07-23"
msgstr "23 juillet 2024"
#. type: TH
#: fedora-44 fedora-rawhide
#, no-wrap
msgid "Linux man-pages 6.13"
msgstr "Pages du manuel de Linux 6.13"
#. type: TH
#: mageia-cauldron
#, no-wrap
msgid "Linux man-pages 6.17"
msgstr "Pages du manuel de Linux 6.17"
#. type: TH
#: opensuse-leap-16-1 opensuse-tumbleweed
#, no-wrap
msgid "Linux man-pages (unreleased)"
msgstr "Pages du manuel de Linux (non publiées)"