pthread_once(3) | Library Functions Manual | pthread_once(3) |
NOM
pthread_once - Exécution unique
SYNOPSIS
#include <pthread.h>
pthread_once_t once_control = PTHREAD_ONCE_INIT;
int pthread_once(pthread_once_t *once_control, void (*init_routine) (void));
DESCRIPTION
The purpose of pthread_once is to ensure that a piece of initialization code is executed at most once. The once_control argument points to a static or extern variable statically initialized to PTHREAD_ONCE_INIT.
The first time pthread_once is called with a given once_control argument, it calls init_routine with no argument and changes the value of the once_control variable to record that initialization has been performed. Subsequent calls to pthread_once with the same once_control argument do nothing.
VALEUR RENVOYÉE
pthread_once() renvoie toujours 0.
ERREURS
Aucun.
TRADUCTION
La traduction française de cette page de manuel a été créée par Gérard Delafond <gerard@delafond.org>, Christophe Blaess <ccb@club-internet.fr>, Thierry Vignaud <tvignaud@mandriva.com>, Alain Portal <aportal@univ-montp2.fr>, Denis Barbier <barbier@debian.org>, Nicolas François <nicolas.francois@centraliens.net>, Florentin Duneau <fduneau@gmail.com>, Thomas Blein <tblein@tblein.eu> et David Prévot <david@tilapin.org>
Cette traduction est une documentation libre ; veuillez vous reporter à la GNU General Public License version 3 concernant les conditions de copie et de distribution. Il n'y a aucune RESPONSABILITÉ LÉGALE.
Si vous découvrez un bogue dans la traduction de cette page de manuel, veuillez envoyer un message à debian-l10n-french@lists.debian.org.
31 octobre 2023 | Pages du manuel de Linux 6.06 |