# 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, 2013-2014. # Denis Barbier , 2006, 2010. # David Prévot , 2010-2014. # Jean-Pierre Giraud , 2024. msgid "" msgstr "" "Project-Id-Version: manpages-l10n 4.21.0\n" "POT-Creation-Date: 2024-06-01 05:51+0200\n" "PO-Revision-Date: 2024-03-14 16:08+0100\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-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "getaddrinfo_a" msgstr "getaddrinfo_a" #. type: TH #: archlinux debian-unstable opensuse-tumbleweed #, no-wrap msgid "2024-05-02" msgstr "2 mai 2024" #. type: TH #: archlinux debian-unstable #, no-wrap msgid "Linux man-pages 6.8" msgstr "Pages du manuel de Linux 6.8" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "NAME" msgstr "NOM" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "getaddrinfo_a, gai_suspend, gai_error, gai_cancel - asynchronous network " "address and service translation" msgstr "" "getaddrinfo_a, gai_suspend, gai_error, gai_cancel – Traduction asynchrone " "d'adresses et de services réseau" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "LIBRARY" msgstr "BIBLIOTHÈQUE" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Asynchronous name lookup library (I, I<-lanl>)" msgstr "Bibliothèque de résolution de noms asynchrone (I, I<-lanl>)" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "SYNOPSIS" msgstr "SYNOPSIS" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "B<#define _GNU_SOURCE> /* See feature_test_macros(7) */\n" "B<#include Enetdb.hE>\n" msgstr "" "B<#define _GNU_SOURCE> /* Consultez feature_test_macros(7) */\n" "B<#include Enetdb.hE>\n" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "BIB<, struct gaicb *>IB<[restrict],>\n" "B< int >IB<, struct sigevent *restrict >IB<);>\n" "BIB<[], int >IB<,>\n" "B< const struct timespec *>IB<);>\n" msgstr "" "BIB<, struct gaicb *>IB<[restrict],>\n" "B< int >IB<, struct sigevent *restrict >IB<);>\n" "BIB<[], int >IB<,>\n" "B< const struct timespec *>IB<);>\n" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "BIB<);>\n" "BIB<);>\n" msgstr "" "BIB<);>\n" "BIB<);>\n" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "DESCRIPTION" msgstr "DESCRIPTION" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() function performs the same task as " "B(3), but allows multiple name look-ups to be performed " "asynchronously, with optional notification on completion of look-up " "operations." msgstr "" "La fonction B() effectue la même opération que " "B(3), mais permet d'effectuer plusieurs résolutions de manière " "asynchrone et de recevoir une notification à chaque résolution effectuée." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The I argument has one of the following values:" msgstr "Le champ I peut prendre une des valeurs suivantes\\ :" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Perform the look-ups synchronously. The call blocks until the look-ups have " "completed." msgstr "" "Effectue les résolutions de manière synchrone. L'appel bloque tant que les " "résolutions ne sont pas terminées." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Perform the look-ups asynchronously. The call returns immediately, and the " "requests are resolved in the background. See the discussion of the I " "argument below." msgstr "" "Effectue les résolutions de manière asynchrone. L'appel s'achève " "immédiatement et les requêtes sont résolues en arrière-plan. Consultez la " "description du paramètre I ci-dessous." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The array I specifies the look-up requests to process. The I " "argument specifies the number of elements in I. The requested look-up " "operations are started in parallel. NULL elements in I are ignored. " "Each request is described by a I structure, defined as follows:" msgstr "" "Le tableau I indique les requêtes de recherche à traiter. Le paramètre " "I indique le nombre d'éléments dans I. Les opérations de " "recherche demandées sont lancées en parallèle. Les éléments égal à NULL de " "I sont ignorés. Chaque requête est décrite par une structure I " "définie ci-dessous\\ :" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "struct gaicb {\n" " const char *ar_name;\n" " const char *ar_service;\n" " const struct addrinfo *ar_request;\n" " struct addrinfo *ar_result;\n" "};\n" msgstr "" "struct gaicb {\n" " const char *ar_name;\n" " const char *ar_service;\n" " const struct addrinfo *ar_request;\n" " struct addrinfo *ar_result;\n" "};\n" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The elements of this structure correspond to the arguments of " "B(3). Thus, I corresponds to the I argument and " "I to the I argument, identifying an Internet host and a " "service. The I element corresponds to the I argument, " "specifying the criteria for selecting the returned socket address " "structures. Finally, I corresponds to the I argument; you " "do not need to initialize this element, it will be automatically set when " "the request is resolved. The I structure referenced by the last " "two elements is described in B(3)." msgstr "" "Les éléments de cette structure correspondent aux paramètres de " "B(3). Ainsi, I correspond au paramètre I et " "I au paramètre I, identifiant respectivement un hôte et " "un service Internet. L'élément I correspond au paramètre " "I, indiquant le critère de sélection des structures d'adresse de " "socket renvoyées. Enfin, I correspond au paramètre I\\ ; " "vous n'avez pas besoin d'initialiser ce paramètre, il sera automatiquement " "défini lorsque la requête sera résolue. La structure I référencée " "par les deux derniers éléments est décrite dans B(3)." #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed msgid "" "When I is specified as B, notifications about resolved " "requests can be obtained by employing the I structure pointed to " "by the I argument. For the definition and general details of this " "structure, see B(3type). The Isigev_notify> field can " "have the following values:" msgstr "" "Lorsque I est défini à B, les notifications des requêtes " "résolues peuvent être obtenues avec la structure I pointée par le " "paramètre I. Pour la définition et les détails généraux de cette " "structure, consultez B(3type). Le champ Isigev_notify> " "peut prendre l'une des valeurs suivantes\\ :" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Don't provide any notification." msgstr "Ne fournit pas de notification." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. si_pid and si_uid are also set, to the values of the calling process, #. which doesn't provide useful information, so we'll skip mentioning it. #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed msgid "" "When a look-up completes, generate the signal I for the " "process. See B(3type) for general details. The I field " "of the I structure will be set to B." msgstr "" "Lorsqu'une recherche se termine, générer le signal I à " "destination du processus. Consultez B(3type) pour plus de détails. " "Le champ I de la structure I sera défini à B." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed msgid "" "When a look-up completes, invoke I as if it were the " "start function of a new thread. See B(3type) for details." msgstr "" "Lors d'une résolution, invoquer I comme si c'était la " "fonction de création d'un nouveau processus léger. Consultez " "B(3type) pour plus détails." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "For B and B, it may be useful to point Isigev_value.sival_ptr> to I." msgstr "" "Pour B et B, il peut être utile de faire pointer " "Isigev_value.sival_ptr> vers I." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() function suspends execution of the calling thread, " "waiting for the completion of one or more requests in the array I. " "The I argument specifies the size of the array I. The call " "blocks until one of the following occurs:" msgstr "" "La fonction B() suspend l'exécution du processus léger " "appelant, attendant la fin d'une ou plusieurs requêtes du tableau I. " "L'argument I indique la taille du tableau I. L'appel est " "bloquant tant que l'un des événements suivants ne se produisent :" #. type: IP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "\\[bu]" msgstr "-" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "One or more of the operations in I completes." msgstr "Une ou plusieurs des opérations de I se sont terminées." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The call is interrupted by a signal that is caught." msgstr "L'appel a été interrompu par un signal qui a été interrompu." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The time interval specified in I elapses. This argument specifies " "a timeout in seconds plus nanoseconds (see B(2) for details of " "the I structure). If I is NULL, then the call blocks " "indefinitely (until one of the events above occurs)." msgstr "" "L'intervalle de temps indiqué dans I s'est écoulé. Ce paramètre " "indique un délai en seconds plus nanosecondes (consultez B(2) " "pour plus de détails sur la structure I). Si I est NULL, " "alors l'appel est bloqué indéfiniment (à moins que l'un des événement ci-" "dessus se produisent)." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "No explicit indication of which request was completed is given; you must " "determine which request(s) have completed by iterating with B() " "over the list of requests." msgstr "" "Aucune indication explicite sur la requête qui s'est terminée est " "fournie\\ ; vous devez déterminer quelle requête s'est terminée en " "parcourant avec B() la liste des requête (il peut y avoir " "plusieurs requêtes)." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() function returns the status of the request I: " "either B if the request was not completed yet, 0 if it was " "handled successfully, or an error code if the request could not be resolved." msgstr "" "La fonction B() renvoie l'état de la requête I\\ : soit " "B si la requête ne s'est pas encore terminée, soit B<0> si " "elle s'est terminé correctement ou soit un code d'erreur si elle ne peut pas " "être résolue." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() function cancels the request I. If the request " "has been canceled successfully, the error status of the request will be set " "to B and normal asynchronous notification will be performed. " "The request cannot be canceled if it is currently being processed; in that " "case, it will be handled as if B() has never been called. If " "I is NULL, an attempt is made to cancel all outstanding requests that " "the process has made." msgstr "" "La fonction B() annule la requête I. Si la requête a été " "annulée avec succès, le statut d'erreur de la requête sera défini à " "B et un notification asynchrone normale sera exécutée. La " "requête ne peut pas être annulée si elle est en cours d'utilisation\\ ; dans " "ce cas, elle continuera comme si B() n'avait jamais été appelée. " "Si I est NULL, une tentative d'annulation de toutes les requêtes en " "cours que le processus a fait sera exécutée." #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "RETURN VALUE" msgstr "VALEUR RENVOYÉE" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() function returns 0 if all of the requests have been " "enqueued successfully, or one of the following nonzero error codes:" msgstr "" "La fonction B() renvoie B<0> si toutes les requêtes ont été " "mises en file d'attente avec succès, ou un des codes d'erreur non nuls " "suivants\\ :" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The resources necessary to enqueue the look-up requests were not available. " "The application may check the error status of each request to determine " "which ones failed." msgstr "" "Les ressources nécessaires pour mettre en file d'attente les requêtes de " "recherche ne sont pas disponibles. L'application devrait vérifier le statut " "d'erreur de chaque requête pour déterminer laquelle a échoué." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Out of memory." msgstr "Plus assez de mémoire." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "I is invalid." msgstr "I est non valable." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() function returns 0 if at least one of the listed " "requests has been completed. Otherwise, it returns one of the following " "nonzero error codes:" msgstr "" "La fonction B() renvoie B<0> si au moins une des requêtes " "listées s'est terminée. Sinon, elle renvoie un des codes d'erreur non nuls " "suivants\\ :" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The given timeout expired before any of the requests could be completed." msgstr "Le délai d'attente a expiré avant que toute requête ne soit terminée." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "There were no actual requests given to the function." msgstr "Il n'y a actuellement aucune requête fournie à la fonction." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "A signal has interrupted the function. Note that this interruption might " "have been caused by signal notification of some completed look-up request." msgstr "" "Un signal a interrompu la fonction. Notez que cette interruption pourrait " "avoir été causé par une notification de signal de fin de certaines requêtes " "de recherche." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B() function can return B for an unfinished " "look-up request, 0 for a successfully completed look-up (as described " "above), one of the error codes that could be returned by B(3), " "or the error code B if the request has been canceled " "explicitly before it could be finished." msgstr "" "La fonction B() peut renvoyer B pour une requête " "de recherche non terminée, B<0> pour une recherche terminée avec succès (cas " "décrit ci-dessus), un des codes d'erreur qui peut être renvoyé par " "B(3), ou le code d'erreur B si la requête a été " "annulée explicitement avant quelle ne soit terminée." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The B() function can return one of these values:" msgstr "La fonction B() peut renvoyer une des valeurs suivantes :" #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The request has been canceled successfully." msgstr "La requête a été annulée avec succès." #. type: TP #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "B" msgstr "B" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The request has not been canceled." msgstr "La requête n'a pas été annulée." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The request has already completed." msgstr "La requête est déjà terminée." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The B(3) function translates these error codes to a human " "readable string, suitable for error reporting." msgstr "" "La fonction B(3) traduit ces codes d'erreur en une chaîne de " "caractères compréhensible, utilisable pour rendre compte du problème." #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "ATTRIBUTES" msgstr "ATTRIBUTS" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 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-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Interface" msgstr "Interface" #. type: tbl table #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Attribute" msgstr "Attribut" #. type: tbl table #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Value" msgstr "Valeur" #. type: tbl table #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed #, no-wrap msgid ".na\n" msgstr ".na\n" #. type: tbl table #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed #, no-wrap msgid ".nh\n" msgstr ".nh\n" #. type: tbl table #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "B(),\n" "B(),\n" "B(),\n" "B()" msgstr "" "B(),\n" "B(),\n" "B(),\n" "B()" #. type: tbl table #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Thread safety" msgstr "Sécurité des threads" #. type: tbl table #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "MT-Safe" msgstr "MT-Safe" #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "STANDARDS" msgstr "STANDARDS" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed msgid "GNU." msgstr "GNU." #. type: SH #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "HISTORY" msgstr "HISTORIQUE" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-leap-15-6 opensuse-tumbleweed msgid "glibc 2.2.3." msgstr "glibc 2.2.3." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The interface of B() was modeled after the B(3) " "interface." msgstr "" "L'interface de B() a été modifiée après l'interface " "B(3)." #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "EXAMPLES" msgstr "EXEMPLES" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "Two examples are provided: a simple example that resolves several requests " "in parallel synchronously, and a complex example showing some of the " "asynchronous capabilities." msgstr "" "Deux exemples sont fournis\\ : un simple exemple qui résout plusieurs " "requête en parallèle de façon synchrone et un exemple complexe montrant " "certaines des capacités asynchrones." #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Synchronous example" msgstr "Exemple synchrone" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "The program below simply resolves several hostnames in parallel, giving a " "speed-up compared to resolving the hostnames sequentially using " "B(3). The program might be used like this:" msgstr "" "Le programme ci-dessous résout simplement plusieurs noms d'hôte en " "parallèle, améliorant le temps de résolution des noms d'hôtes comparé à des " "appels séquentiels à B(3). Le programme peut être utilisé comme " "suit\\ :" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "$ B<./a.out mirrors.kernel.org enoent.linuxfoundation.org gnu.org>\n" "mirrors.kernel.org: 139.178.88.99\n" "enoent.linuxfoundation.org: Name or service not known\n" "gnu.org: 209.51.188.116\n" msgstr "" "$ B<./a.out mirrors.kernel.org enoent.linuxfoundation.org gnu.org>\n" "mirrors.kernel.org: 139.178.88.99\n" "enoent.linuxfoundation.org: Name or service not known\n" "gnu.org: 209.51.188.116\n" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "Here is the program source code" msgstr "Voilà le code source du programme" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed #, no-wrap msgid "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Enetdb.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "\\&\n" "#define MALLOC(n, type) ((type *) reallocarray(NULL, n, sizeof(type)))\n" "\\&\n" "int\n" "main(int argc, char *argv[])\n" "{\n" " int ret;\n" " struct gaicb *reqs[argc - 1];\n" " char host[NI_MAXHOST];\n" " struct addrinfo *res;\n" "\\&\n" " if (argc E 2) {\n" " fprintf(stderr, \"Usage: %s HOST...\\en\", argv[0]);\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " for (size_t i = 0; i E argc - 1; i++) {\n" " reqs[i] = MALLOC(1, struct gaicb);\n" " if (reqs[i] == NULL)\n" " err(EXIT_FAILURE, \"malloc\");\n" "\\&\n" " memset(reqs[i], 0, sizeof(*reqs[0]));\n" " reqs[i]-Ear_name = argv[i + 1];\n" " }\n" "\\&\n" " ret = getaddrinfo_a(GAI_WAIT, reqs, argc - 1, NULL);\n" " if (ret != 0) {\n" " fprintf(stderr, \"getaddrinfo_a() failed: %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " for (size_t i = 0; i E argc - 1; i++) {\n" " printf(\"%s: \", reqs[i]-Ear_name);\n" " ret = gai_error(reqs[i]);\n" " if (ret == 0) {\n" " res = reqs[i]-Ear_result;\n" "\\&\n" " ret = getnameinfo(res-Eai_addr, res-Eai_addrlen,\n" " host, sizeof(host),\n" " NULL, 0, NI_NUMERICHOST);\n" " if (ret != 0) {\n" " fprintf(stderr, \"getnameinfo() failed: %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" " puts(host);\n" "\\&\n" " } else {\n" " puts(gai_strerror(ret));\n" " }\n" " }\n" " exit(EXIT_SUCCESS);\n" "}\n" msgstr "" "#define _GNU_SOURCE\n" "#include Eerr.hE\n" "#include Enetdb.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "\\&\n" "#define MALLOC(n, type) ((type *) reallocarray(NULL, n, sizeof(type)))\n" "\\&\n" "int\n" "main(int argc, char *argv[])\n" "{\n" " int ret;\n" " struct gaicb *reqs[argc - 1];\n" " char host[NI_MAXHOST];\n" " struct addrinfo *res;\n" "\\&\n" " if (argc E 2) {\n" " fprintf(stderr, \"Utilisation : %s HOST...\\en\", argv[0]);\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " for (size_t i = 0; i E argc - 1; i++) {\n" " reqs[i] = MALLOC(1, struct gaicb);\n" " if (reqs[i] == NULL)\n" " err(EXIT_FAILURE, \"malloc\");\n" "\\&\n" " memset(reqs[i], 0, sizeof(*reqs[0]));\n" " reqs[i]-Ear_name = argv[i + 1];\n" " }\n" "\\&\n" " ret = getaddrinfo_a(GAI_WAIT, reqs, argc - 1, NULL);\n" " if (ret != 0) {\n" " fprintf(stderr, \"getaddrinfo_a() a échoué : %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" "\\&\n" " for (size_t i = 0; i E argc - 1; i++) {\n" " printf(\"%s: \", reqs[i]-Ear_name);\n" " ret = gai_error(reqs[i]);\n" " if (ret == 0) {\n" " res = reqs[i]-Ear_result;\n" "\\&\n" " ret = getnameinfo(res-Eai_addr, res-Eai_addrlen,\n" " host, sizeof(host),\n" " NULL, 0, NI_NUMERICHOST);\n" " if (ret != 0) {\n" " fprintf(stderr, \"getnameinfo() a échoué : %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" " puts(host);\n" "\\&\n" " } else {\n" " puts(gai_strerror(ret));\n" " }\n" " }\n" " exit(EXIT_SUCCESS);\n" "}\n" #. SRC END #. type: SS #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "Asynchronous example" msgstr "Exemple asynchrone" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "" "This example shows a simple interactive B() front-end. The " "notification facility is not demonstrated." msgstr "" "Cet exemple est une simple application interactive utilisant " "B(). Les fonctionnalités de notification ne sont pas " "exploitées." #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "An example session might look like this:" msgstr "Un exemple de session pourrait ressembler à ceci\\ :" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "" "$ B<./a.out>\n" "E a mirrors.kernel.org enoent.linuxfoundation.org gnu.org\n" "E c 2\n" "[2] gnu.org: Request not canceled\n" "E w 0 1\n" "[00] mirrors.kernel.org: Finished\n" "E l\n" "[00] mirrors.kernel.org: 139.178.88.99\n" "[01] enoent.linuxfoundation.org: Processing request in progress\n" "[02] gnu.org: 209.51.188.116\n" "E l\n" "[00] mirrors.kernel.org: 139.178.88.99\n" "[01] enoent.linuxfoundation.org: Name or service not known\n" "[02] gnu.org: 209.51.188.116\n" msgstr "" "$ B<./a.out>\n" "E a mirrors.kernel.org enoent.linuxfoundation.org gnu.org\n" "E c 2\n" "[2] gnu.org: Request not canceled\n" "E w 0 1\n" "[00] mirrors.kernel.org: Finished\n" "E l\n" "[00] mirrors.kernel.org: 139.178.88.99\n" "[01] enoent.linuxfoundation.org: Processing request in progress\n" "[02] gnu.org: 209.51.188.116\n" "E l\n" "[00] mirrors.kernel.org: 139.178.88.99\n" "[01] enoent.linuxfoundation.org: Name or service not known\n" "[02] gnu.org: 209.51.188.116\n" #. type: Plain text #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed msgid "The program source is as follows:" msgstr "Le code source du programme est\\ :" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed #, no-wrap msgid "" "#define _GNU_SOURCE\n" "#include Eassert.hE\n" "#include Eerr.hE\n" "#include Enetdb.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "\\&\n" "#define CALLOC(n, type) ((type *) calloc(n, sizeof(type)))\n" "\\&\n" "#define REALLOCF(ptr, n, type) \\e\n" "({ \\e\n" " static_assert(__builtin_types_compatible_p(typeof(ptr), type *)); \\e\n" " \\e\n" " (type *) reallocarrayf(ptr, n, sizeof(type)); \\e\n" "})\n" "\\&\n" "static struct gaicb **reqs = NULL;\n" "static size_t nreqs = 0;\n" "\\&\n" "static inline void *\n" "reallocarrayf(void *p, size_t nmemb, size_t size)\n" "{\n" " void *q;\n" "\\&\n" " q = reallocarray(p, nmemb, size);\n" " if (q == NULL && nmemb != 0 && size != 0)\n" " free(p);\n" " return q;\n" "}\n" "\\&\n" "static char *\n" "getcmd(void)\n" "{\n" " static char buf[256];\n" "\\&\n" " fputs(\"E \", stdout); fflush(stdout);\n" " if (fgets(buf, sizeof(buf), stdin) == NULL)\n" " return NULL;\n" "\\&\n" " if (buf[strlen(buf) - 1] == \\[aq]\\en\\[aq])\n" " buf[strlen(buf) - 1] = 0;\n" "\\&\n" " return buf;\n" "}\n" "\\&\n" "/* Add requests for specified hostnames. */\n" "static void\n" "add_requests(void)\n" "{\n" " size_t nreqs_base = nreqs;\n" " char *host;\n" " int ret;\n" "\\&\n" " while ((host = strtok(NULL, \" \"))) {\n" " nreqs++;\n" " reqs = REALLOCF(reqs, nreqs, struct gaicb *);\n" " if (reqs == NULL)\n" " err(EXIT_FAILURE, \"reallocf\");\n" "\\&\n" " reqs[nreqs - 1] = CALLOC(1, struct gaicb);\n" " if (reqs[nreqs - 1] == NULL)\n" " err(EXIT_FAILURE, \"calloc\");\n" "\\&\n" " reqs[nreqs - 1]-Ear_name = strdup(host);\n" " }\n" "\\&\n" " /* Queue nreqs_base..nreqs requests. */\n" "\\&\n" " ret = getaddrinfo_a(GAI_NOWAIT, &reqs[nreqs_base],\n" " nreqs - nreqs_base, NULL);\n" " if (ret) {\n" " fprintf(stderr, \"getaddrinfo_a() failed: %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" "}\n" "\\&\n" "/* Wait until at least one of specified requests completes. */\n" "static void\n" "wait_requests(void)\n" "{\n" " char *id;\n" " int ret;\n" " size_t n;\n" " struct gaicb const **wait_reqs;\n" "\\&\n" " wait_reqs = CALLOC(nreqs, const struct gaicb *);\n" " if (wait_reqs == NULL)\n" " err(EXIT_FAILURE, \"calloc\");\n" "\\&\n" " /* NULL elements are ignored by gai_suspend(). */\n" "\\&\n" " while ((id = strtok(NULL, \" \")) != NULL) {\n" " n = atoi(id);\n" "\\&\n" " if (n E= nreqs) {\n" " printf(\"Bad request number: %s\\en\", id);\n" " return;\n" " }\n" "\\&\n" " wait_reqs[n] = reqs[n];\n" " }\n" "\\&\n" " ret = gai_suspend(wait_reqs, nreqs, NULL);\n" " if (ret) {\n" " printf(\"gai_suspend(): %s\\en\", gai_strerror(ret));\n" " return;\n" " }\n" "\\&\n" " for (size_t i = 0; i E nreqs; i++) {\n" " if (wait_reqs[i] == NULL)\n" " continue;\n" "\\&\n" " ret = gai_error(reqs[i]);\n" " if (ret == EAI_INPROGRESS)\n" " continue;\n" "\\&\n" " printf(\"[%02zu] %s: %s\\en\", i, reqs[i]-Ear_name,\n" " ret == 0 ? \"Finished\" : gai_strerror(ret));\n" " }\n" "}\n" "\\&\n" "/* Cancel specified requests. */\n" "static void\n" "cancel_requests(void)\n" "{\n" " char *id;\n" " int ret;\n" " size_t n;\n" "\\&\n" " while ((id = strtok(NULL, \" \")) != NULL) {\n" " n = atoi(id);\n" "\\&\n" " if (n E= nreqs) {\n" " printf(\"Bad request number: %s\\en\", id);\n" " return;\n" " }\n" "\\&\n" " ret = gai_cancel(reqs[n]);\n" " printf(\"[%s] %s: %s\\en\", id, reqs[atoi(id)]-Ear_name,\n" " gai_strerror(ret));\n" " }\n" "}\n" "\\&\n" "/* List all requests. */\n" "static void\n" "list_requests(void)\n" "{\n" " int ret;\n" " char host[NI_MAXHOST];\n" " struct addrinfo *res;\n" "\\&\n" " for (size_t i = 0; i E nreqs; i++) {\n" " printf(\"[%02zu] %s: \", i, reqs[i]-Ear_name);\n" " ret = gai_error(reqs[i]);\n" "\\&\n" " if (!ret) {\n" " res = reqs[i]-Ear_result;\n" "\\&\n" " ret = getnameinfo(res-Eai_addr, res-Eai_addrlen,\n" " host, sizeof(host),\n" " NULL, 0, NI_NUMERICHOST);\n" " if (ret) {\n" " fprintf(stderr, \"getnameinfo() failed: %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" " puts(host);\n" " } else {\n" " puts(gai_strerror(ret));\n" " }\n" " }\n" "}\n" "\\&\n" "int\n" "main(void)\n" "{\n" " char *cmdline;\n" " char *cmd;\n" "\\&\n" " while ((cmdline = getcmd()) != NULL) {\n" " cmd = strtok(cmdline, \" \");\n" "\\&\n" " if (cmd == NULL) {\n" " list_requests();\n" " } else {\n" " switch (cmd[0]) {\n" " case \\[aq]a\\[aq]:\n" " add_requests();\n" " break;\n" " case \\[aq]w\\[aq]:\n" " wait_requests();\n" " break;\n" " case \\[aq]c\\[aq]:\n" " cancel_requests();\n" " break;\n" " case \\[aq]l\\[aq]:\n" " list_requests();\n" " break;\n" " default:\n" " fprintf(stderr, \"Bad command: %c\\en\", cmd[0]);\n" " break;\n" " }\n" " }\n" " }\n" " exit(EXIT_SUCCESS);\n" "}\n" msgstr "" "#define _GNU_SOURCE\n" "#include Eassert.hE\n" "#include Eerr.hE\n" "#include Enetdb.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" "\\&\n" "#define CALLOC(n, type) ((type *) calloc(n, sizeof(type)))\n" "\\&\n" "#define REALLOCF(ptr, n, type) \\e\n" "({ \\e\n" " static_assert(__builtin_types_compatible_p(typeof(ptr), type *)); \\e\n" " \\e\n" " (type *) reallocarrayf(ptr, n, sizeof(type)); \\e\n" "})\n" "\\&\n" "static struct gaicb **reqs = NULL;\n" "static size_t nreqs = 0;\n" "\\&\n" "static inline void *\n" "reallocarrayf(void *p, size_t nmemb, size_t size)\n" "{\n" " void *q;\n" "\\&\n" " q = reallocarray(p, nmemb, size);\n" " if (q == NULL && nmemb != 0 && size != 0)\n" " free(p);\n" " return q;\n" "}\n" "\\&\n" "static char *\n" "getcmd(void)\n" "{\n" " static char buf[256];\n" "\\&\n" " fputs(\"E \", stdout); fflush(stdout);\n" " if (fgets(buf, sizeof(buf), stdin) == NULL)\n" " return NULL;\n" "\\&\n" " if (buf[strlen(buf) - 1] == \\[aq]\\en\\[aq])\n" " buf[strlen(buf) - 1] = 0;\n" "\\&\n" " return buf;\n" "}\n" "\\&\n" "/* Ajout des requêtes pour les noms d'hôte spécifiés. */\n" "static void\n" "add_requests(void)\n" "{\n" " size_t nreqs_base = nreqs;\n" " char *host;\n" " int ret;\n" "\\&\n" " while ((host = strtok(NULL, \" \"))) {\n" " nreqs++;\n" " reqs = REALLOCF(reqs, nreqs, struct gaicb *);\n" " if (reqs == NULL)\n" " err(EXIT_FAILURE, \"reallocf\");\n" "\\&\n" " reqs[nreqs - 1] = CALLOC(1, struct gaicb);\n" " if (reqs[nreqs - 1] == NULL)\n" " err(EXIT_FAILURE, \"calloc\");\n" "\\&\n" " reqs[nreqs - 1]-Ear_name = strdup(host);\n" " }\n" "\\&\n" " /* Mettre en file d'attente les requêtes nreqs_base..nreqs. */\n" "\\&\n" " ret = getaddrinfo_a(GAI_NOWAIT, &reqs[nreqs_base],\n" " nreqs - nreqs_base, NULL);\n" " if (ret) {\n" " fprintf(stderr, \"getaddrinfo_a() a échoué : %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" "}\n" "\\&\n" "/* Attendre qu'au moins une des requêtes spécifiées soit achevée. */\n" "static void\n" "wait_requests(void)\n" "{\n" " char *id;\n" " int ret;\n" " size_t n;\n" " struct gaicb const **wait_reqs;\n" "\\&\n" " wait_reqs = CALLOC(nreqs, const struct gaicb *);\n" " if (wait_reqs == NULL)\n" " err(EXIT_FAILURE, \"calloc\");\n" "\\&\n" " /* Les éléments NULL sont ignorés par gai_suspend(). */\n" "\\&\n" " while ((id = strtok(NULL, \" \")) != NULL) {\n" " n = atoi(id);\n" "\\&\n" " if (n E= nreqs) {\n" " printf(\"Mauvais nombre de requêtes : %s\\en\", id);\n" " return;\n" " }\n" "\\&\n" " wait_reqs[n] = reqs[n];\n" " }\n" "\\&\n" " ret = gai_suspend(wait_reqs, nreqs, NULL);\n" " if (ret) {\n" " printf(\"gai_suspend(): %s\\en\", gai_strerror(ret));\n" " return;\n" " }\n" "\\&\n" " for (size_t i = 0; i E nreqs; i++) {\n" " if (wait_reqs[i] == NULL)\n" " continue;\n" "\\&\n" " ret = gai_error(reqs[i]);\n" " if (ret == EAI_INPROGRESS)\n" " continue;\n" "\\&\n" " printf(\"[%02zu] %s: %s\\en\", i, reqs[i]-Ear_name,\n" " ret == 0 ? \"Terminé\" : gai_strerror(ret));\n" " }\n" "}\n" "\\&\n" "/* Annuler les requêtes spécifiées. */\n" "static void\n" "cancel_requests(void)\n" "{\n" " char *id;\n" " int ret;\n" " size_t n;\n" "\\&\n" " while ((id = strtok(NULL, \" \")) != NULL) {\n" " n = atoi(id);\n" "\\&\n" " if (n E= nreqs) {\n" " printf(\"Mauvais nombre de requêtes : %s\\en\", id);\n" " return;\n" " }\n" "\\&\n" " ret = gai_cancel(reqs[n]);\n" " printf(\"[%s] %s: %s\\en\", id, reqs[atoi(id)]-Ear_name,\n" " gai_strerror(ret));\n" " }\n" "}\n" "\\&\n" "/* Lister toutes les requêtes. */\n" "static void\n" "list_requests(void)\n" "{\n" " int ret;\n" " char host[NI_MAXHOST];\n" " struct addrinfo *res;\n" "\\&\n" " for (size_t i = 0; i E nreqs; i++) {\n" " printf(\"[%02zu] %s: \", i, reqs[i]-Ear_name);\n" " ret = gai_error(reqs[i]);\n" "\\&\n" " if (!ret) {\n" " res = reqs[i]-Ear_result;\n" "\\&\n" " ret = getnameinfo(res-Eai_addr, res-Eai_addrlen,\n" " host, sizeof(host),\n" " NULL, 0, NI_NUMERICHOST);\n" " if (ret) {\n" " fprintf(stderr, \"getnameinfo() a échoué : %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" " puts(host);\n" " } else {\n" " puts(gai_strerror(ret));\n" " }\n" " }\n" "}\n" "\\&\n" "int\n" "main(void)\n" "{\n" " char *cmdline;\n" " char *cmd;\n" "\\&\n" " while ((cmdline = getcmd()) != NULL) {\n" " cmd = strtok(cmdline, \" \");\n" "\\&\n" " if (cmd == NULL) {\n" " list_requests();\n" " } else {\n" " switch (cmd[0]) {\n" " case \\[aq]a\\[aq]:\n" " add_requests();\n" " break;\n" " case \\[aq]w\\[aq]:\n" " wait_requests();\n" " break;\n" " case \\[aq]c\\[aq]:\n" " cancel_requests();\n" " break;\n" " case \\[aq]l\\[aq]:\n" " list_requests();\n" " break;\n" " default:\n" " fprintf(stderr, \"Mauvaise commande : %c\\en\", cmd[0]);\n" " break;\n" " }\n" " }\n" " }\n" " exit(EXIT_SUCCESS);\n" "}\n" #. SRC END #. type: SH #: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide #: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed #, no-wrap msgid "SEE ALSO" msgstr "VOIR AUSSI" #. type: Plain text #: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron #: opensuse-tumbleweed msgid "" "B(3), B(3), B(3), B(7), B(7), " "B(3type)" msgstr "" "B(3), B(3), B(3), B(7), B(7), " "B(3type)" #. type: TH #: debian-bookworm #, no-wrap msgid "2023-02-05" msgstr "5 février 2023" #. type: TH #: debian-bookworm #, no-wrap msgid "Linux man-pages 6.03" msgstr "Pages du manuel de Linux 6.03" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 msgid "" "When I is specified as B, notifications about resolved " "requests can be obtained by employing the I structure pointed to " "by the I argument. For the definition and general details of this " "structure, see B(7). The Isigev_notify> field can have " "the following values:" msgstr "" "Lorsque I est défini à B, les notifications des requêtes " "résolues peuvent être obtenues avec la structure I pointée par le " "paramètre I. Pour la définition et les détails généraux de cette " "structure, consultez B(7). Le champ Isigev_notify> peut " "prendre l'une des valeurs suivantes\\ :" #. si_pid and si_uid are also set, to the values of the calling process, #. which doesn't provide useful information, so we'll skip mentioning it. #. type: Plain text #: debian-bookworm opensuse-leap-15-6 msgid "" "When a look-up completes, generate the signal I for the " "process. See B(7) for general details. The I field of " "the I structure will be set to B." msgstr "" "Lorsqu'une recherche se termine, générer le signal I à " "destination du processus. Consultez B(7) pour plus de détails. Le " "champ I de la structure I sera défini à B." #. type: Plain text #: debian-bookworm opensuse-leap-15-6 msgid "" "When a look-up completes, invoke I as if it were the " "start function of a new thread. See B(7) for details." msgstr "" "Lors d'une résolution, invoquer I comme si c'était la " "fonction de création d'un nouveau processus léger. Consultez B(7) " "pour plus détails." #. type: Plain text #: debian-bookworm msgid "These functions are GNU extensions; they first appeared in glibc 2.2.3." msgstr "" "Ces fonctions sont des extensions GNU. Elles ont été introduites dans la " "glibc 2.2.3." #. type: SH #: debian-bookworm #, no-wrap msgid "NOTES" msgstr "NOTES" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "#define _GNU_SOURCE\n" "#include Enetdb.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" msgstr "" "#define _GNU_SOURCE\n" "#include Enetdb.hE\n" "#include Estdio.hE\n" "#include Estdlib.hE\n" "#include Estring.hE\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "int\n" "main(int argc, char *argv[])\n" "{\n" " int ret;\n" " struct gaicb *reqs[argc - 1];\n" " char host[NI_MAXHOST];\n" " struct addrinfo *res;\n" msgstr "" "int\n" "main(int argc, char *argv[])\n" "{\n" " int ret;\n" " struct gaicb *reqs[argc - 1];\n" " char host[NI_MAXHOST];\n" " struct addrinfo *res;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (argc E 2) {\n" " fprintf(stderr, \"Usage: %s HOST...\\en\", argv[0]);\n" " exit(EXIT_FAILURE);\n" " }\n" msgstr "" " if (argc E 2) {\n" " fprintf(stderr, \"Utilisation : %s HOST...\\en\", argv[0]);\n" " exit(EXIT_FAILURE);\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " for (size_t i = 0; i E argc - 1; i++) {\n" " reqs[i] = malloc(sizeof(*reqs[0]));\n" " if (reqs[i] == NULL) {\n" " perror(\"malloc\");\n" " exit(EXIT_FAILURE);\n" " }\n" " memset(reqs[i], 0, sizeof(*reqs[0]));\n" " reqs[i]-Ear_name = argv[i + 1];\n" " }\n" msgstr "" " for (size_t i = 0; i E argc - 1; i++) {\n" " reqs[i] = malloc(sizeof(*reqs[0]));\n" " if (reqs[i] == NULL) {\n" " perror(\"malloc\");\n" " exit(EXIT_FAILURE);\n" " }\n" " memset(reqs[i], 0, sizeof(*reqs[0]));\n" " reqs[i]-Ear_name = argv[i + 1];\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " ret = getaddrinfo_a(GAI_WAIT, reqs, argc - 1, NULL);\n" " if (ret != 0) {\n" " fprintf(stderr, \"getaddrinfo_a() failed: %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" msgstr "" " ret = getaddrinfo_a(GAI_WAIT, reqs, argc - 1, NULL);\n" " if (ret != 0) {\n" " fprintf(stderr, \"getaddrinfo_a() a échoué : %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " for (size_t i = 0; i E argc - 1; i++) {\n" " printf(\"%s: \", reqs[i]-Ear_name);\n" " ret = gai_error(reqs[i]);\n" " if (ret == 0) {\n" " res = reqs[i]-Ear_result;\n" msgstr "" " for (size_t i = 0; i E argc - 1; i++) {\n" " printf(\"%s: \", reqs[i]-Ear_name);\n" " ret = gai_error(reqs[i]);\n" " if (ret == 0) {\n" " res = reqs[i]-Ear_result;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " ret = getnameinfo(res-Eai_addr, res-Eai_addrlen,\n" " host, sizeof(host),\n" " NULL, 0, NI_NUMERICHOST);\n" " if (ret != 0) {\n" " fprintf(stderr, \"getnameinfo() failed: %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" " puts(host);\n" msgstr "" " ret = getnameinfo(res-Eai_addr, res-Eai_addrlen,\n" " host, sizeof(host),\n" " NULL, 0, NI_NUMERICHOST);\n" " if (ret != 0) {\n" " fprintf(stderr, \"getnameinfo() a échoué : %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" " puts(host);\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " } else {\n" " puts(gai_strerror(ret));\n" " }\n" " }\n" " exit(EXIT_SUCCESS);\n" "}\n" msgstr "" " } else {\n" " puts(gai_strerror(ret));\n" " }\n" " }\n" " exit(EXIT_SUCCESS);\n" "}\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "static struct gaicb **reqs = NULL;\n" "static size_t nreqs = 0;\n" msgstr "" "static struct gaicb **reqs = NULL;\n" "static size_t nreqs = 0;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "static char *\n" "getcmd(void)\n" "{\n" " static char buf[256];\n" msgstr "" "static char *\n" "getcmd(void)\n" "{\n" " static char buf[256];\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " fputs(\"E \", stdout); fflush(stdout);\n" " if (fgets(buf, sizeof(buf), stdin) == NULL)\n" " return NULL;\n" msgstr "" " fputs(\"E \", stdout); fflush(stdout);\n" " if (fgets(buf, sizeof(buf), stdin) == NULL)\n" " return NULL;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (buf[strlen(buf) - 1] == \\[aq]\\en\\[aq])\n" " buf[strlen(buf) - 1] = 0;\n" msgstr "" " if (buf[strlen(buf) - 1] == \\[aq]\\en\\[aq])\n" " buf[strlen(buf) - 1] = 0;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " return buf;\n" "}\n" msgstr "" " return buf;\n" "}\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "/* Add requests for specified hostnames. */\n" "static void\n" "add_requests(void)\n" "{\n" " size_t nreqs_base = nreqs;\n" " char *host;\n" " int ret;\n" msgstr "" "/* Ajout des requêtes pour les noms d'hôte spécifiés. */\n" "static void\n" "add_requests(void)\n" "{\n" " size_t nreqs_base = nreqs;\n" " char *host;\n" " int ret;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " while ((host = strtok(NULL, \" \"))) {\n" " nreqs++;\n" " reqs = realloc(reqs, sizeof(reqs[0]) * nreqs);\n" msgstr "" " while ((host = strtok(NULL, \" \"))) {\n" " nreqs++;\n" " reqs = realloc(reqs, sizeof(reqs[0]) * nreqs);\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " reqs[nreqs - 1] = calloc(1, sizeof(*reqs[0]));\n" " reqs[nreqs - 1]-Ear_name = strdup(host);\n" " }\n" msgstr "" " reqs[nreqs - 1] = calloc(1, sizeof(*reqs[0]));\n" " reqs[nreqs - 1]-Ear_name = strdup(host);\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid " /* Queue nreqs_base..nreqs requests. */\n" msgstr " /* Mettre en file d'attente les requêtes nreqs_base..nreqs. */\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " ret = getaddrinfo_a(GAI_NOWAIT, &reqs[nreqs_base],\n" " nreqs - nreqs_base, NULL);\n" " if (ret) {\n" " fprintf(stderr, \"getaddrinfo_a() failed: %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" "}\n" msgstr "" " ret = getaddrinfo_a(GAI_NOWAIT, &reqs[nreqs_base],\n" " nreqs - nreqs_base, NULL);\n" " if (ret) {\n" " fprintf(stderr, \"getaddrinfo_a() a échoué : %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" "}\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "/* Wait until at least one of specified requests completes. */\n" "static void\n" "wait_requests(void)\n" "{\n" " char *id;\n" " int ret;\n" " size_t n;\n" " struct gaicb const **wait_reqs = calloc(nreqs, sizeof(*wait_reqs));\n" " /* NULL elements are ignored by gai_suspend(). */\n" msgstr "" "/* Attendre qu'au moins une des requêtes spécifiées soit achevée. */\n" "static void\n" "wait_requests(void)\n" "{\n" " char *id;\n" " int ret;\n" " size_t n;\n" " struct gaicb const **wait_reqs = calloc(nreqs, sizeof(*wait_reqs));\n" " /* Les éléments NULL sont ignorés par gai_suspend(). */\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " while ((id = strtok(NULL, \" \")) != NULL) {\n" " n = atoi(id);\n" msgstr "" " while ((id = strtok(NULL, \" \")) != NULL) {\n" " n = atoi(id);\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (n E= nreqs) {\n" " printf(\"Bad request number: %s\\en\", id);\n" " return;\n" " }\n" msgstr "" " if (n E= nreqs) {\n" " printf(\"Mauvais nombre de requêtes : %s\\en\", id);\n" " return;\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " wait_reqs[n] = reqs[n];\n" " }\n" msgstr "" " wait_reqs[n] = reqs[n];\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " ret = gai_suspend(wait_reqs, nreqs, NULL);\n" " if (ret) {\n" " printf(\"gai_suspend(): %s\\en\", gai_strerror(ret));\n" " return;\n" " }\n" msgstr "" " ret = gai_suspend(wait_reqs, nreqs, NULL);\n" " if (ret) {\n" " printf(\"gai_suspend() : %s\\en\", gai_strerror(ret));\n" " return;\n" " }\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " for (size_t i = 0; i E nreqs; i++) {\n" " if (wait_reqs[i] == NULL)\n" " continue;\n" msgstr "" " for (size_t i = 0; i E nreqs; i++) {\n" " if (wait_reqs[i] == NULL)\n" " continue;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " ret = gai_error(reqs[i]);\n" " if (ret == EAI_INPROGRESS)\n" " continue;\n" msgstr "" " ret = gai_error(reqs[i]);\n" " if (ret == EAI_INPROGRESS)\n" " continue;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " printf(\"[%02zu] %s: %s\\en\", i, reqs[i]-Ear_name,\n" " ret == 0 ? \"Finished\" : gai_strerror(ret));\n" " }\n" "}\n" msgstr "" " printf(\"[%02zu] %s: %s\\en\", i, reqs[i]-Ear_name,\n" " ret == 0 ? \"Terminé\" : gai_strerror(ret));\n" " }\n" "}\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "/* Cancel specified requests. */\n" "static void\n" "cancel_requests(void)\n" "{\n" " char *id;\n" " int ret;\n" " size_t n;\n" msgstr "" "/* Annuler les requêtes spécifiées. */\n" "static void\n" "cancel_requests(void)\n" "{\n" " char *id;\n" " int ret;\n" " size_t n;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " ret = gai_cancel(reqs[n]);\n" " printf(\"[%s] %s: %s\\en\", id, reqs[atoi(id)]-Ear_name,\n" " gai_strerror(ret));\n" " }\n" "}\n" msgstr "" " ret = gai_cancel(reqs[n]);\n" " printf(\"[%s] %s: %s\\en\", id, reqs[atoi(id)]-Ear_name,\n" " gai_strerror(ret));\n" " }\n" "}\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "/* List all requests. */\n" "static void\n" "list_requests(void)\n" "{\n" " int ret;\n" " char host[NI_MAXHOST];\n" " struct addrinfo *res;\n" msgstr "" "/* Lister toutes les requêtes. */\n" "static void\n" "list_requests(void)\n" "{\n" " int ret;\n" " char host[NI_MAXHOST];\n" " struct addrinfo *res;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " for (size_t i = 0; i E nreqs; i++) {\n" " printf(\"[%02zu] %s: \", i, reqs[i]-Ear_name);\n" " ret = gai_error(reqs[i]);\n" msgstr "" " for (size_t i = 0; i E nreqs; i++) {\n" " printf(\"[%02zu] %s: \", i, reqs[i]-Ear_name);\n" " ret = gai_error(reqs[i]);\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (!ret) {\n" " res = reqs[i]-Ear_result;\n" msgstr "" " if (!ret) {\n" " res = reqs[i]-Ear_result;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " ret = getnameinfo(res-Eai_addr, res-Eai_addrlen,\n" " host, sizeof(host),\n" " NULL, 0, NI_NUMERICHOST);\n" " if (ret) {\n" " fprintf(stderr, \"getnameinfo() failed: %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" " puts(host);\n" " } else {\n" " puts(gai_strerror(ret));\n" " }\n" " }\n" "}\n" msgstr "" " ret = getnameinfo(res-Eai_addr, res-Eai_addrlen,\n" " host, sizeof(host),\n" " NULL, 0, NI_NUMERICHOST);\n" " if (ret) {\n" " fprintf(stderr, \"getnameinfo() a échoué : %s\\en\",\n" " gai_strerror(ret));\n" " exit(EXIT_FAILURE);\n" " }\n" " puts(host);\n" " } else {\n" " puts(gai_strerror(ret));\n" " }\n" " }\n" "}\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" "int\n" "main(void)\n" "{\n" " char *cmdline;\n" " char *cmd;\n" msgstr "" "int\n" "main(void)\n" "{\n" " char *cmdline;\n" " char *cmd;\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " while ((cmdline = getcmd()) != NULL) {\n" " cmd = strtok(cmdline, \" \");\n" msgstr "" " while ((cmdline = getcmd()) != NULL) {\n" " cmd = strtok(cmdline, \" \");\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 #, no-wrap msgid "" " if (cmd == NULL) {\n" " list_requests();\n" " } else {\n" " switch (cmd[0]) {\n" " case \\[aq]a\\[aq]:\n" " add_requests();\n" " break;\n" " case \\[aq]w\\[aq]:\n" " wait_requests();\n" " break;\n" " case \\[aq]c\\[aq]:\n" " cancel_requests();\n" " break;\n" " case \\[aq]l\\[aq]:\n" " list_requests();\n" " break;\n" " default:\n" " fprintf(stderr, \"Bad command: %c\\en\", cmd[0]);\n" " break;\n" " }\n" " }\n" " }\n" " exit(EXIT_SUCCESS);\n" "}\n" msgstr "" " if (cmd == NULL) {\n" " list_requests();\n" " } else {\n" " switch (cmd[0]) {\n" " case \\[aq]a\\[aq]:\n" " add_requests();\n" " break;\n" " case \\[aq]w\\[aq]:\n" " wait_requests();\n" " break;\n" " case \\[aq]c\\[aq]:\n" " cancel_requests();\n" " break;\n" " case \\[aq]l\\[aq]:\n" " list_requests();\n" " break;\n" " default:\n" " fprintf(stderr, \"Mauvaise commande : %c\\en\", cmd[0]);\n" " break;\n" " }\n" " }\n" " }\n" " exit(EXIT_SUCCESS);\n" "}\n" #. type: Plain text #: debian-bookworm opensuse-leap-15-6 msgid "" "B(3), B(3), B(3), B(7), B(7), " "B(7)" msgstr "" "B(3), B(3), B(3), B(7), B(7), " "B(7)" #. type: TH #: fedora-40 fedora-rawhide mageia-cauldron #, no-wrap msgid "2023-10-31" msgstr "31 octobre 2023" #. type: TH #: fedora-40 mageia-cauldron #, no-wrap msgid "Linux man-pages 6.06" msgstr "Pages du manuel de Linux 6.06" #. type: TH #: fedora-rawhide #, no-wrap msgid "Linux man-pages 6.7" msgstr "Pages du manuel de Linux 6.7" #. type: TH #: opensuse-leap-15-6 #, no-wrap msgid "2023-03-30" msgstr "30 mars 2023" #. type: TH #: opensuse-leap-15-6 #, no-wrap msgid "Linux man-pages 6.04" msgstr "Pages du manuel de Linux 6.04" #. type: TH #: opensuse-tumbleweed #, no-wrap msgid "Linux man-pages (unreleased)" msgstr "Pages du manuel de Linux (non publiées)"