| 1 |
# French translation of manpages |
| 2 |
# This file is distributed under the same license as the manpages-l10n package. |
| 3 |
# Copyright © of this file: |
| 4 |
# Christophe Blaess <https://www.blaess.fr/christophe/>, 1996-2003. |
| 5 |
# Stéphan Rafin <[email protected]>, 2002. |
| 6 |
# Thierry Vignaud <[email protected]>, 1999, 2002. |
| 7 |
# François Micaux, 2002. |
| 8 |
# Alain Portal <[email protected]>, 2003-2008. |
| 9 |
# Jean-Philippe Guérard <[email protected]>, 2005-2006. |
| 10 |
# Jean-Luc Coulon (f5ibh) <[email protected]>, 2006-2007. |
| 11 |
# Julien Cristau <[email protected]>, 2006-2007. |
| 12 |
# Thomas Huriaux <[email protected]>, 2006-2008. |
| 13 |
# Nicolas François <[email protected]>, 2006-2008. |
| 14 |
# Florentin Duneau <[email protected]>, 2006-2010. |
| 15 |
# Simon Paillard <[email protected]>, 2006, 2013-2014. |
| 16 |
# Denis Barbier <[email protected]>, 2006, 2010. |
| 17 |
# David Prévot <[email protected]>, 2010-2014. |
| 18 |
# Jean-Pierre Giraud <[email protected]>, 2023-2024. |
| 19 |
msgid "" |
| 20 |
msgstr "" |
| 21 |
"Project-Id-Version: manpages-l10n 4.22.0\n" |
| 22 |
"POT-Creation-Date: 2026-06-05 06:25+0200\n" |
| 23 |
"PO-Revision-Date: 2024-06-02 14:07+0200\n" |
| 24 |
"Last-Translator: Jean-Pierre Giraud <[email protected]>\n" |
| 25 |
"Language-Team: French <[email protected]>\n" |
| 26 |
"Language: fr\n" |
| 27 |
"MIME-Version: 1.0\n" |
| 28 |
"Content-Type: text/plain; charset=UTF-8\n" |
| 29 |
"Content-Transfer-Encoding: 8bit\n" |
| 30 |
"Plural-Forms: nplurals=2; plural=n > 1;\n" |
| 31 |
"X-Generator: Lokalize 22.12.3\n" |
| 32 |
|
| 33 |
#. type: TH |
| 34 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 35 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 36 |
#, no-wrap |
| 37 |
msgid "getaddrinfo" |
| 38 |
msgstr "getaddrinfo" |
| 39 |
|
| 40 |
#. type: TH |
| 41 |
#: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1 |
| 42 |
#: opensuse-tumbleweed |
| 43 |
#, no-wrap |
| 44 |
msgid "2026-02-08" |
| 45 |
msgstr "8 février 2026" |
| 46 |
|
| 47 |
#. type: TH |
| 48 |
#: archlinux debian-unstable |
| 49 |
#, no-wrap |
| 50 |
msgid "Linux man-pages 6.18" |
| 51 |
msgstr "Pages du manuel de Linux 6.18" |
| 52 |
|
| 53 |
#. type: SH |
| 54 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 55 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 56 |
#, no-wrap |
| 57 |
msgid "NAME" |
| 58 |
msgstr "NOM" |
| 59 |
|
| 60 |
#. type: Plain text |
| 61 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 62 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 63 |
msgid "" |
| 64 |
"getaddrinfo, freeaddrinfo, gai_strerror - network address and service " |
| 65 |
"translation" |
| 66 |
msgstr "" |
| 67 |
"getaddrinfo, freeaddrinfo, gai_strerror - Traduction d'adresses et de " |
| 68 |
"services réseau" |
| 69 |
|
| 70 |
#. type: SH |
| 71 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 72 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 73 |
#, no-wrap |
| 74 |
msgid "LIBRARY" |
| 75 |
msgstr "BIBLIOTHÈQUE" |
| 76 |
|
| 77 |
#. type: Plain text |
| 78 |
#: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron |
| 79 |
#: opensuse-leap-16-1 opensuse-tumbleweed |
| 80 |
msgid "Standard C library (I<libc>,\\ I<-lc>)" |
| 81 |
msgstr "Bibliothèque C standard (I<libc>,\\ I<-lc>)" |
| 82 |
|
| 83 |
#. type: SH |
| 84 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 85 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 86 |
#, no-wrap |
| 87 |
msgid "SYNOPSIS" |
| 88 |
msgstr "SYNOPSIS" |
| 89 |
|
| 90 |
#. type: Plain text |
| 91 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 92 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 93 |
#, no-wrap |
| 94 |
msgid "" |
| 95 |
"B<#include E<lt>sys/types.hE<gt>>\n" |
| 96 |
"B<#include E<lt>sys/socket.hE<gt>>\n" |
| 97 |
"B<#include E<lt>netdb.hE<gt>>\n" |
| 98 |
msgstr "" |
| 99 |
"B<#include E<lt>sys/types.hE<gt>>\n" |
| 100 |
"B<#include E<lt>sys/socket.hE<gt>>\n" |
| 101 |
"B<#include E<lt>netdb.hE<gt>>\n" |
| 102 |
|
| 103 |
#. type: Plain text |
| 104 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 105 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 106 |
#, no-wrap |
| 107 |
msgid "" |
| 108 |
"B<int getaddrinfo(const char *restrict >I<node>B<,>\n" |
| 109 |
"B< const char *restrict >I<service>B<,>\n" |
| 110 |
"B< const struct addrinfo *restrict >I<hints>B<,>\n" |
| 111 |
"B< struct addrinfo **restrict >I<res>B<);>\n" |
| 112 |
msgstr "" |
| 113 |
"B<int getaddrinfo(const char *restrict >I<node>B<,>\n" |
| 114 |
"B< const char *restrict >I<service>B<,>\n" |
| 115 |
"B< const struct addrinfo *restrict >I<hints>B<,>\n" |
| 116 |
"B< struct addrinfo **restrict >I<res>B<);>\n" |
| 117 |
|
| 118 |
#. type: Plain text |
| 119 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 120 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 121 |
#, no-wrap |
| 122 |
msgid "B<void freeaddrinfo(struct addrinfo *>I<res>B<);>\n" |
| 123 |
msgstr "B<void freeaddrinfo(struct addrinfo *>I<res>B<);>\n" |
| 124 |
|
| 125 |
#. type: Plain text |
| 126 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 127 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 128 |
#, no-wrap |
| 129 |
msgid "B<const char *gai_strerror(int >I<errcode>B<);>\n" |
| 130 |
msgstr "B<const char *gai_strerror(int >I<errcode>B<);>\n" |
| 131 |
|
| 132 |
#. type: Plain text |
| 133 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 134 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 135 |
msgid "" |
| 136 |
"Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):" |
| 137 |
msgstr "" |
| 138 |
"Exigences de macros de test de fonctionnalités pour la glibc (consulter " |
| 139 |
"B<feature_test_macros>(7)) :" |
| 140 |
|
| 141 |
#. type: Plain text |
| 142 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 143 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 144 |
msgid "B<getaddrinfo>(), B<freeaddrinfo>(), B<gai_strerror>():" |
| 145 |
msgstr "B<getaddrinfo>(), B<freeaddrinfo>(), B<gai_strerror>() :" |
| 146 |
|
| 147 |
#. type: Plain text |
| 148 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 149 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 150 |
#, no-wrap |
| 151 |
msgid "" |
| 152 |
" Since glibc 2.22:\n" |
| 153 |
" _POSIX_C_SOURCE E<gt>= 200112L\n" |
| 154 |
" glibc 2.21 and earlier:\n" |
| 155 |
" _POSIX_C_SOURCE\n" |
| 156 |
msgstr "" |
| 157 |
" Depuis la glibc 2.22 :\n" |
| 158 |
" _POSIX_C_SOURCE E<gt>= 200112L\n" |
| 159 |
" glibc 2.21 et antérieures :\n" |
| 160 |
" _POSIX_C_SOURCE\n" |
| 161 |
|
| 162 |
#. type: SH |
| 163 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 164 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 165 |
#, no-wrap |
| 166 |
msgid "DESCRIPTION" |
| 167 |
msgstr "DESCRIPTION" |
| 168 |
|
| 169 |
#. .BR getipnodebyname (3), |
| 170 |
#. .BR getipnodebyaddr (3), |
| 171 |
#. type: Plain text |
| 172 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 173 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 174 |
msgid "" |
| 175 |
"Given I<node> and I<service>, which identify an Internet host and a service, " |
| 176 |
"B<getaddrinfo>() returns one or more I<addrinfo> structures, each of which " |
| 177 |
"contains an Internet address that can be specified in a call to B<bind>(2) " |
| 178 |
"or B<connect>(2). The B<getaddrinfo>() function combines the functionality " |
| 179 |
"provided by the B<gethostbyname>(3) and B<getservbyname>(3) functions into " |
| 180 |
"a single interface, but unlike the latter functions, B<getaddrinfo>() is " |
| 181 |
"reentrant and allows programs to eliminate IPv4-versus-IPv6 dependencies." |
| 182 |
msgstr "" |
| 183 |
"Étant donnés I<node> et I<service>, qui identifient un hôte Internet et un " |
| 184 |
"service, B<getaddrinfo>() renvoie une ou plusieurs structure I<addrinfo>, " |
| 185 |
"chacune d'entre elles contenant une adresse Internet qui puisse être " |
| 186 |
"indiquée dans un appel à B<bind>(2) ou B<connect>(2). La fonction " |
| 187 |
"B<getaddrinfo>() combine la fonctionnalité fournie par les fonctions " |
| 188 |
"B<gethostbyname>(3) et B<getservbyname>(3) en une interface unique, mais à " |
| 189 |
"l'inverse de ces fonctions, B<getaddrinfo>() est réentrante et permet aux " |
| 190 |
"programmes d'éliminer la dépendance envers IPv4 ou IPv6." |
| 191 |
|
| 192 |
#. type: Plain text |
| 193 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 194 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 195 |
msgid "" |
| 196 |
"The I<addrinfo> structure used by B<getaddrinfo>() contains the following " |
| 197 |
"fields:" |
| 198 |
msgstr "" |
| 199 |
"La structure I<addrinfo> utilisée par B<getaddrinfo>() contient les membres " |
| 200 |
"suivants\\ :" |
| 201 |
|
| 202 |
#. type: Plain text |
| 203 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 204 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 205 |
#, no-wrap |
| 206 |
msgid "" |
| 207 |
"struct addrinfo {\n" |
| 208 |
" int ai_flags;\n" |
| 209 |
" int ai_family;\n" |
| 210 |
" int ai_socktype;\n" |
| 211 |
" int ai_protocol;\n" |
| 212 |
" socklen_t ai_addrlen;\n" |
| 213 |
" struct sockaddr *ai_addr;\n" |
| 214 |
" char *ai_canonname;\n" |
| 215 |
" struct addrinfo *ai_next;\n" |
| 216 |
"};\n" |
| 217 |
msgstr "" |
| 218 |
"struct addrinfo {\n" |
| 219 |
" int ai_flags;\n" |
| 220 |
" int ai_family;\n" |
| 221 |
" int ai_socktype;\n" |
| 222 |
" int ai_protocol;\n" |
| 223 |
" socklen_t ai_addrlen;\n" |
| 224 |
" struct sockaddr *ai_addr;\n" |
| 225 |
" char *ai_canonname;\n" |
| 226 |
" struct addrinfo *ai_next;\n" |
| 227 |
"};\n" |
| 228 |
|
| 229 |
#. type: Plain text |
| 230 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 231 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 232 |
msgid "" |
| 233 |
"The I<hints> argument points to an I<addrinfo> structure that specifies " |
| 234 |
"criteria for selecting the socket address structures returned in the list " |
| 235 |
"pointed to by I<res>. If I<hints> is not NULL it points to an I<addrinfo> " |
| 236 |
"structure whose I<ai_family>, I<ai_socktype>, and I<ai_protocol> specify " |
| 237 |
"criteria that limit the set of socket addresses returned by " |
| 238 |
"B<getaddrinfo>(), as follows:" |
| 239 |
msgstr "" |
| 240 |
"Le paramètre I<hints> pointe sur une structure I<addrinfo> qui indique les " |
| 241 |
"critères de sélection des structures d'adresses de sockets renvoyées dans la " |
| 242 |
"liste pointée par I<res>. Si I<hints> n'est pas NULL, il doit pointer sur " |
| 243 |
"une structure I<addrinfo> dont les membres I<ai_family>, I<ai_socktype>, et " |
| 244 |
"I<ai_protocol> indiquent les critères limitant l'ensemble d'adresses de " |
| 245 |
"sockets renvoyées par B<getaddrinfo>(), de la façon suivante :" |
| 246 |
|
| 247 |
#. type: TP |
| 248 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 249 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 250 |
#, no-wrap |
| 251 |
msgid "I<ai_family>" |
| 252 |
msgstr "I<ai_family>" |
| 253 |
|
| 254 |
#. type: Plain text |
| 255 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 256 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 257 |
msgid "" |
| 258 |
"This field specifies the desired address family for the returned addresses. " |
| 259 |
"Valid values for this field include B<AF_INET> and B<AF_INET6>. The value " |
| 260 |
"B<AF_UNSPEC> indicates that B<getaddrinfo>() should return socket addresses " |
| 261 |
"for any address family (either IPv4 or IPv6, for example) that can be used " |
| 262 |
"with I<node> and I<service>." |
| 263 |
msgstr "" |
| 264 |
"Ce champ indique la famille d'adresse désirée des adresses renvoyées. " |
| 265 |
"B<AF_INET> et B<AF_INET6> font partie des valeurs valables pour ce champ. La " |
| 266 |
"valeur B<AF_UNSPEC> indique que B<getaddrinfo>() doit renvoyer les adresses " |
| 267 |
"de socket de n'importe quelle famille d'adresses (par exemple, IPv4 ou IPv6) " |
| 268 |
"pouvant être utilisées avec I<node> et I<service>." |
| 269 |
|
| 270 |
#. type: TP |
| 271 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 272 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 273 |
#, no-wrap |
| 274 |
msgid "I<ai_socktype>" |
| 275 |
msgstr "I<ai_socktype>" |
| 276 |
|
| 277 |
#. type: Plain text |
| 278 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 279 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 280 |
msgid "" |
| 281 |
"This field specifies the preferred socket type, for example B<SOCK_STREAM> " |
| 282 |
"or B<SOCK_DGRAM>. Specifying 0 in this field indicates that socket " |
| 283 |
"addresses of any type can be returned by B<getaddrinfo>()." |
| 284 |
msgstr "" |
| 285 |
"Ce champ indique le type préféré de socket, par exemple B<SOCK_STREAM> ou " |
| 286 |
"B<SOCK_DGRAM>. Mettre 0 dans ce champ indique que B<getaddrinfo>() peut " |
| 287 |
"renvoyer n'importe quel type d'adresse de socket." |
| 288 |
|
| 289 |
#. type: TP |
| 290 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 291 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 292 |
#, no-wrap |
| 293 |
msgid "I<ai_protocol>" |
| 294 |
msgstr "I<ai_protocol>" |
| 295 |
|
| 296 |
#. type: Plain text |
| 297 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 298 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 299 |
msgid "" |
| 300 |
"This field specifies the protocol for the returned socket addresses. " |
| 301 |
"Specifying 0 in this field indicates that socket addresses with any protocol " |
| 302 |
"can be returned by B<getaddrinfo>()." |
| 303 |
msgstr "" |
| 304 |
"Ce champ indique le protocole des adresses de socket renvoyées. Mettre 0 " |
| 305 |
"dans ce champ indique que B<getaddrinfo>() peut renvoyer des adresses de " |
| 306 |
"socket de n'importe quel type." |
| 307 |
|
| 308 |
#. type: TP |
| 309 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 310 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 311 |
#, no-wrap |
| 312 |
msgid "I<ai_flags>" |
| 313 |
msgstr "I<ai_flags>" |
| 314 |
|
| 315 |
#. type: Plain text |
| 316 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 317 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 318 |
msgid "" |
| 319 |
"This field specifies additional options, described below. Multiple flags " |
| 320 |
"are specified by bitwise OR-ing them together." |
| 321 |
msgstr "" |
| 322 |
"Ce champ indique des options supplémentaires, décrites ci-dessous. Plusieurs " |
| 323 |
"attributs peuvent être indiqués en les groupant par un OU binaire." |
| 324 |
|
| 325 |
#. type: Plain text |
| 326 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 327 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 328 |
msgid "" |
| 329 |
"All the other fields in the structure pointed to by I<hints> must contain " |
| 330 |
"either 0 or a null pointer, as appropriate." |
| 331 |
msgstr "" |
| 332 |
"Tous les autres membres de la structure pointée par I<hints> doivent " |
| 333 |
"contenir 0 ou être des pointeurs NULL." |
| 334 |
|
| 335 |
#. type: Plain text |
| 336 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 337 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 338 |
msgid "" |
| 339 |
"Specifying I<hints> as NULL is equivalent to setting I<ai_socktype> and " |
| 340 |
"I<ai_protocol> to 0; I<ai_family> to B<AF_UNSPEC>; and I<ai_flags> to " |
| 341 |
"B<(AI_V4MAPPED\\ |\\ AI_ADDRCONFIG)>. (POSIX specifies different defaults " |
| 342 |
"for I<ai_flags>; see NOTES.) I<node> specifies either a numerical network " |
| 343 |
"address (for IPv4, numbers-and-dots notation as supported by " |
| 344 |
"B<inet_aton>(3); for IPv6, hexadecimal string format as supported by " |
| 345 |
"B<inet_pton>(3)), or a network hostname, whose network addresses are looked " |
| 346 |
"up and resolved. If I<hints.ai_flags> contains the B<AI_NUMERICHOST> flag, " |
| 347 |
"then I<node> must be a numerical network address. The B<AI_NUMERICHOST> " |
| 348 |
"flag suppresses any potentially lengthy network host address lookups." |
| 349 |
msgstr "" |
| 350 |
"Spécifier I<hints> à NULL est équivalent à définir I<ai_socktype> et " |
| 351 |
"I<ai_protocol> à 0, I<ai_family> à B<AF_UNSPEC> et I<ai_flags> à " |
| 352 |
"B<(AI_V4MAPPED\\ |\\ AI_ADDRCONFIG)>. (POSIX spécifie d'autres valeurs par " |
| 353 |
"défaut pour I<ai_flags> ; consultez les NOTES.) I<node> indique soit une " |
| 354 |
"adresse réseau en format numérique (décimal pointé pour l'IPv4, comme prise " |
| 355 |
"en charge par B<inet_aton>(3) ; hexadécimal pour l'IPv6, comme prise en " |
| 356 |
"charge par B<inet_pton>(3)), soit un nom d'hôte, dont l'adresse réseau est " |
| 357 |
"alors résolue. Si le membre I<hints.ai_flags> contient l'attribut " |
| 358 |
"B<AI_NUMERICHOST> alors I<node> devra être une adresse réseau numérique. " |
| 359 |
"L'attribut B<AI_NUMERICHOST> empêche toute tentative, éventuellement longue, " |
| 360 |
"de résolution de nom d'hôte." |
| 361 |
|
| 362 |
#. type: Plain text |
| 363 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 364 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 365 |
msgid "" |
| 366 |
"If the B<AI_PASSIVE> flag is specified in I<hints.ai_flags>, and I<node> is " |
| 367 |
"NULL, then the returned socket addresses will be suitable for B<bind>(2)ing " |
| 368 |
"a socket that will B<accept>(2) connections. The returned socket address " |
| 369 |
"will contain the \"wildcard address\" (B<INADDR_ANY> for IPv4 addresses, " |
| 370 |
"B<IN6ADDR_ANY_INIT> for IPv6 address). The wildcard address is used by " |
| 371 |
"applications (typically servers) that intend to accept connections on any " |
| 372 |
"of the host's network addresses. If I<node> is not NULL, then the " |
| 373 |
"B<AI_PASSIVE> flag is ignored." |
| 374 |
msgstr "" |
| 375 |
"Si l'attribut B<AI_PASSIVE> est indiqué dans I<hints.ai_flags>, et si " |
| 376 |
"I<node> est NULL, les adresses de socket renvoyées seront pertinentes pour " |
| 377 |
"lier (B<bind>(2)) un socket qui acceptera (B<accept>(2)) les connexions. Les " |
| 378 |
"adresses de socket renvoyées contiendront l'« adresse joker » (wildcard " |
| 379 |
"adress) (B<INADDR_ANY> pour les adresses IPv4, B<IN6ADDR_ANY_INIT> pour les " |
| 380 |
"adresses IPv6). L'« adresse joker » est utilisée par des applications " |
| 381 |
"(typiquement des serveurs) qui ont l'intention d'accepter des connexions de " |
| 382 |
"n'importe quel hôte. Si I<node> n'est pas NULL, l'attribut B<AI_PASSIVE> est " |
| 383 |
"ignoré." |
| 384 |
|
| 385 |
#. type: Plain text |
| 386 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 387 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 388 |
msgid "" |
| 389 |
"If the B<AI_PASSIVE> flag is not set in I<hints.ai_flags>, then the returned " |
| 390 |
"socket addresses will be suitable for use with B<connect>(2), B<sendto>(2), " |
| 391 |
"or B<sendmsg>(2). If I<node> is NULL, then the network address will be set " |
| 392 |
"to the loopback interface address (B<INADDR_LOOPBACK> for IPv4 addresses, " |
| 393 |
"B<IN6ADDR_LOOPBACK_INIT> for IPv6 address); this is used by applications " |
| 394 |
"that intend to communicate with peers running on the same host." |
| 395 |
msgstr "" |
| 396 |
"Si l'attribut B<AI_PASSIVE> n'est pas positionné dans I<hints.ai_flags>, les " |
| 397 |
"adresses de socket renvoyées seront pertinentes pour être utilisées avec " |
| 398 |
"B<connect>(2), B<sendto>(2) ou B<sendmsg>(2). Si I<node> est NULL, l'adresse " |
| 399 |
"réseau sera définie avec l'adresse de l'interface de boucle (loopback) " |
| 400 |
"(B<INADDR_LOOPBACK> pour les adresses IPv4, B<IN6ADDR_LOOPBACK_INIT> pour " |
| 401 |
"les adresses IPv6) ; cela est utilisé par les applications qui doivent " |
| 402 |
"communiquer avec des correspondants s'exécutant sur la même machine." |
| 403 |
|
| 404 |
#. type: Plain text |
| 405 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 406 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 407 |
msgid "" |
| 408 |
"I<service> sets the port in each returned address structure. If this " |
| 409 |
"argument is a service name (see B<services>(5)), it is translated to the " |
| 410 |
"corresponding port number. This argument can also be specified as a decimal " |
| 411 |
"number, which is simply converted to binary. If I<service> is NULL, then " |
| 412 |
"the port number of the returned socket addresses will be left " |
| 413 |
"uninitialized. If B<AI_NUMERICSERV> is specified in I<hints.ai_flags> and " |
| 414 |
"I<service> is not NULL, then I<service> must point to a string containing a " |
| 415 |
"numeric port number. This flag is used to inhibit the invocation of a name " |
| 416 |
"resolution service in cases where it is known not to be required." |
| 417 |
msgstr "" |
| 418 |
"I<service> définit le port dans chacune des structures d'adresses renvoyées. " |
| 419 |
"Si cet argument est un nom de service (consultez B<services>(5)), il est " |
| 420 |
"convertit en son numéro de port correspondant. Cet argument peut également " |
| 421 |
"être indiqué sous forme décimale, qui est simplement converti en binaire. Si " |
| 422 |
"I<service> est NULL, le numéro de port des adresses de socket renvoyées " |
| 423 |
"n'est pas initialisé. Si B<AI_NUMERICSERV> est indiqué dans " |
| 424 |
"I<hints.ai_flags> et si I<service> n'est pas NULL, I<service> doit pointer " |
| 425 |
"vers une chaîne contenant une valeur numérique de port. Cet attribut est " |
| 426 |
"utilisé pour inhiber l'invocation du service de résolution des noms dans les " |
| 427 |
"cas où l'on sait qu'il n'est pas nécessaire." |
| 428 |
|
| 429 |
#. type: Plain text |
| 430 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 431 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 432 |
msgid "Either I<node> or I<service>, but not both, may be NULL." |
| 433 |
msgstr "I<node> ou I<service> peuvent être NULL, mais pas les deux à la fois." |
| 434 |
|
| 435 |
#. type: Plain text |
| 436 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 437 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 438 |
msgid "" |
| 439 |
"The B<getaddrinfo>() function allocates and initializes a linked list of " |
| 440 |
"I<addrinfo> structures, one for each network address that matches I<node> " |
| 441 |
"and I<service>, subject to any restrictions imposed by I<hints>, and returns " |
| 442 |
"a pointer to the start of the list in I<res>. The items in the linked list " |
| 443 |
"are linked by the I<ai_next> field." |
| 444 |
msgstr "" |
| 445 |
"La fonction B<getaddrinfo>() alloue et initialise une liste chaînée de " |
| 446 |
"structures I<addrinfo>, une pour chaque adresse réseau correspondant à " |
| 447 |
"I<node> et I<service>, soumise aux restrictions imposées par l'argument " |
| 448 |
"I<hints>, et renvoie dans I<res> un pointeur sur le début de la liste. Les " |
| 449 |
"éléments de la liste sont chaînés par le champ I<ai_next>." |
| 450 |
|
| 451 |
#. type: Plain text |
| 452 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 453 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 454 |
msgid "" |
| 455 |
"There are several reasons why the linked list may have more than one " |
| 456 |
"I<addrinfo> structure, including: the network host is multihomed, accessible " |
| 457 |
"over multiple protocols (e.g., both B<AF_INET> and B<AF_INET6>); or the same " |
| 458 |
"service is available from multiple socket types (one B<SOCK_STREAM> address " |
| 459 |
"and another B<SOCK_DGRAM> address, for example). Normally, the application " |
| 460 |
"should try using the addresses in the order in which they are returned. The " |
| 461 |
"sorting function used within B<getaddrinfo>() is defined in RFC\\ 3484; the " |
| 462 |
"order can be tweaked for a particular system by editing I</etc/gai.conf> " |
| 463 |
"(available since glibc 2.5)." |
| 464 |
msgstr "" |
| 465 |
"Il y a plusieurs raisons pour lesquelles la liste chaînée peut avoir plus " |
| 466 |
"d'une structure I<addrinfo>\\ : l'hôte réseau est « multihomed » ; le même " |
| 467 |
"service est accessible depuis plusieurs protocoles (par exemple B<AF_INET> " |
| 468 |
"et B<AF_INET6>) ou accessible depuis plusieurs types de socket (par exemple " |
| 469 |
"une adresse de type B<SOCK_STREAM> et une autre de type B<SOCK_DGRAM>). " |
| 470 |
"Normalement, l'application essaie d'utiliser les adresses dans l'ordre où " |
| 471 |
"elles sont renvoyées. La fonction de tri utilisée dans B<getaddrinfo>() est " |
| 472 |
"définie dans la RFC\\ 3484\\ ; le tri peut être configuré pour un système " |
| 473 |
"particulier avec le fichier I</etc/gai.conf> (disponible depuis la glibc\\ " |
| 474 |
"2.5)." |
| 475 |
|
| 476 |
#. Prior to glibc 2.3.4, the ai_canonname of each addrinfo |
| 477 |
#. structure was set pointing to the canonical name; that was |
| 478 |
#. more than POSIX.1-2001 specified, or other implementations provided. |
| 479 |
#. MTK, Aug 05 |
| 480 |
#. type: Plain text |
| 481 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 482 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 483 |
msgid "" |
| 484 |
"If I<hints.ai_flags> includes the B<AI_CANONNAME> flag, then the " |
| 485 |
"I<ai_canonname> field of the first of the I<addrinfo> structures in the " |
| 486 |
"returned list is set to point to the official name of the host." |
| 487 |
msgstr "" |
| 488 |
"Si I<hints.ai_flags> contient l'attribut B<AI_CANONNAME>, le champ " |
| 489 |
"I<ai_canonname> de la première structure I<addrinfo> de la liste renvoyée " |
| 490 |
"est défini pour pointer vers le nom officiel de l'hôte." |
| 491 |
|
| 492 |
#. type: Plain text |
| 493 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 494 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 495 |
msgid "" |
| 496 |
"The remaining fields of each returned I<addrinfo> structure are initialized " |
| 497 |
"as follows:" |
| 498 |
msgstr "" |
| 499 |
"Les champs restants de chaque structure I<addrinfo> renvoyée sont " |
| 500 |
"initialisés de la façon suivante :" |
| 501 |
|
| 502 |
#. type: IP |
| 503 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 504 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 505 |
#, no-wrap |
| 506 |
msgid "\\[bu]" |
| 507 |
msgstr "-" |
| 508 |
|
| 509 |
#. type: Plain text |
| 510 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 511 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 512 |
msgid "" |
| 513 |
"The I<ai_family>, I<ai_socktype>, and I<ai_protocol> fields return the " |
| 514 |
"socket creation parameters (i.e., these fields have the same meaning as the " |
| 515 |
"corresponding arguments of B<socket>(2)). For example, I<ai_family> might " |
| 516 |
"return B<AF_INET> or B<AF_INET6>; I<ai_socktype> might return B<SOCK_DGRAM> " |
| 517 |
"or B<SOCK_STREAM>; and I<ai_protocol> returns the protocol for the socket." |
| 518 |
msgstr "" |
| 519 |
"Les champs I<ai_family>, I<ai_socktype> et I<ai_protocol> renvoient les " |
| 520 |
"paramètres de création de la socket (c'est-à-dire que ces champs ont la même " |
| 521 |
"signification que les paramètres correspondants de B<socket>(2)). Par " |
| 522 |
"exemple, I<ai_family> pourrait renvoyer B<AF_INET> ou B<AF_INET6> ; " |
| 523 |
"I<ai_socktype> pourrait renvoyer B<SOCK_DGRAM> ou B<SOCK_STREAM> ; et " |
| 524 |
"I<ai_protocol> renvoie le protocole de la socket." |
| 525 |
|
| 526 |
#. type: Plain text |
| 527 |
#: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron |
| 528 |
#: opensuse-leap-16-1 opensuse-tumbleweed |
| 529 |
msgid "" |
| 530 |
"A pointer to the socket address is placed in the I<ai_addr> field, and the " |
| 531 |
"size of the socket address, in bytes, is placed in the I<ai_addrlen> field." |
| 532 |
msgstr "" |
| 533 |
"Un pointeur vers l'adresse de la socket est placé dans le champ I<ai_addr>, " |
| 534 |
"et la taille de l'adresse de la socket, en octets, est inscrite dans le " |
| 535 |
"champ I<ai_addrlen> de la structure." |
| 536 |
|
| 537 |
#. type: Plain text |
| 538 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 539 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 540 |
msgid "" |
| 541 |
"If I<hints.ai_flags> includes the B<AI_ADDRCONFIG> flag, then IPv4 addresses " |
| 542 |
"are returned in the list pointed to by I<res> only if the local system has " |
| 543 |
"at least one IPv4 address configured, and IPv6 addresses are returned only " |
| 544 |
"if the local system has at least one IPv6 address configured. The loopback " |
| 545 |
"address is not considered for this case as valid as a configured address. " |
| 546 |
"This flag is useful on, for example, IPv4-only systems, to ensure that " |
| 547 |
"B<getaddrinfo>() does not return IPv6 socket addresses that would always " |
| 548 |
"fail in B<connect>(2) or B<bind>(2)." |
| 549 |
msgstr "" |
| 550 |
"Si I<hints.ai_flags> inclut l'attribut B<AI_ADDRCONFIG>, alors des adresses " |
| 551 |
"IPv4 sont renvoyées dans la liste pointée par I<res> seulement si le système " |
| 552 |
"local possède au moins une adresse IPv4 configurée. Des adresses IPv6 sont " |
| 553 |
"seulement renvoyées si le système local possède au moins une adresse IPv6 " |
| 554 |
"configurée. Dans ce cas, l'adresse de boucle n'est pas considérée comme une " |
| 555 |
"adresse configurée valable. Cet attribut est par exemple utile sur les " |
| 556 |
"systèmes uniquement en IPv4, pour s’assurer que B<getaddrinfo>() ne renvoie " |
| 557 |
"pas d’adresse de socket IPv6 qui échouerait toujours dans B<connect>(2) ou " |
| 558 |
"B<bind>(2)." |
| 559 |
|
| 560 |
#. type: Plain text |
| 561 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 562 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 563 |
msgid "" |
| 564 |
"If I<hints.ai_flags> specifies the B<AI_V4MAPPED> flag, and " |
| 565 |
"I<hints.ai_family> was specified as B<AF_INET6>, and no matching IPv6 " |
| 566 |
"addresses could be found, then return IPv4-mapped IPv6 addresses in the list " |
| 567 |
"pointed to by I<res>. If both B<AI_V4MAPPED> and B<AI_ALL> are specified in " |
| 568 |
"I<hints.ai_flags>, then return both IPv6 and IPv4-mapped IPv6 addresses in " |
| 569 |
"the list pointed to by I<res>. B<AI_ALL> is ignored if B<AI_V4MAPPED> is " |
| 570 |
"not also specified." |
| 571 |
msgstr "" |
| 572 |
"Si I<hints.ai_flags> indique le drapeau B<AI_V4MAPPED>, et si " |
| 573 |
"I<hints.ai_family> a été indiqué avec B<AF_INET6> et qu'aucune adresse IPv6 " |
| 574 |
"correspondante n'a pu être trouvée, alors des adresses IPv4 au format IPv6 " |
| 575 |
"sont renvoyées dans la liste pointée par I<res>. Si B<AI_V4MAPPED> et " |
| 576 |
"B<AI_ALL> sont indiqués dans I<hints.ai_flags>, des adresses IPv6 et des " |
| 577 |
"adresses IPv4 au format IPv6 sont renvoyées dans la liste pointée par " |
| 578 |
"I<res>. B<AI_ALL> est ignoré si B<AI_V4MAPPED> n'est pas aussi indiqué." |
| 579 |
|
| 580 |
#. type: Plain text |
| 581 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 582 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 583 |
msgid "" |
| 584 |
"The B<freeaddrinfo>() function frees the memory that was allocated for the " |
| 585 |
"dynamically allocated linked list I<res>." |
| 586 |
msgstr "" |
| 587 |
"La fonction B<freeaddrinfo>() libère la mémoire qui a été allouée " |
| 588 |
"dynamiquement pour la liste chaînée I<res>." |
| 589 |
|
| 590 |
#. type: SS |
| 591 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 592 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 593 |
#, no-wrap |
| 594 |
msgid "Extensions to getaddrinfo() for Internationalized Domain Names" |
| 595 |
msgstr "Extensions de getaddrinfo() pour les noms de domaines internationalisés" |
| 596 |
|
| 597 |
#. type: Plain text |
| 598 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 599 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 600 |
msgid "" |
| 601 |
"Starting with glibc 2.3.4, B<getaddrinfo>() has been extended to " |
| 602 |
"selectively allow the incoming and outgoing hostnames to be transparently " |
| 603 |
"converted to and from the Internationalized Domain Name (IDN) format (see " |
| 604 |
"RFC 3490, I<Internationalizing Domain Names in Applications (IDNA)>). Four " |
| 605 |
"new flags are defined:" |
| 606 |
msgstr "" |
| 607 |
"Depuis la glibc\\ 2.3.4, B<getaddrinfo>() a été modifié pour sélectivement " |
| 608 |
"permettre que les noms d'hôtes entrant et sortant soient convertis vers ou " |
| 609 |
"depuis le format des noms de domaines internationalisés (IDN). Consultez la " |
| 610 |
"RFC\\ 3490, I<Internationalizing Domain Names in Applications (IDNA)>. " |
| 611 |
"Quatre nouveaux attributs ont été ajoutés\\ :" |
| 612 |
|
| 613 |
#. type: TP |
| 614 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 615 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 616 |
#, no-wrap |
| 617 |
msgid "B<AI_IDN>" |
| 618 |
msgstr "B<AI_IDN>" |
| 619 |
|
| 620 |
#. type: Plain text |
| 621 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 622 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 623 |
msgid "" |
| 624 |
"If this flag is specified, then the node name given in I<node> is converted " |
| 625 |
"to IDN format if necessary. The source encoding is that of the current " |
| 626 |
"locale." |
| 627 |
msgstr "" |
| 628 |
"Si cet attribut est défini, alors le nom du nœud contenu dans I<node> est " |
| 629 |
"converti dans le format IDN si nécessaire. Le format d'encodage choisi est " |
| 630 |
"celui de la locale du système." |
| 631 |
|
| 632 |
#. Implementation Detail: |
| 633 |
#. To minimize effects on system performance the implementation might |
| 634 |
#. want to check whether the input string contains any non-ASCII |
| 635 |
#. characters. If there are none the IDN step can be skipped completely. |
| 636 |
#. On systems which allow not-ASCII safe encodings for a locale this |
| 637 |
#. might be a problem. |
| 638 |
#. type: Plain text |
| 639 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 640 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 641 |
msgid "" |
| 642 |
"If the input name contains non-ASCII characters, then the IDN encoding is " |
| 643 |
"used. Those parts of the node name (delimited by dots) that contain non-" |
| 644 |
"ASCII characters are encoded using ASCII Compatible Encoding (ACE) before " |
| 645 |
"being passed to the name resolution functions." |
| 646 |
msgstr "" |
| 647 |
"Si le nom du nœud contient des caractères non ASCII, alors le format IDN est " |
| 648 |
"utilisé. Ces parties du nom du nœud (séparées par des points) qui " |
| 649 |
"contiennent des caractères non ASCI sont encodées avec «\\ ASCII Compatible " |
| 650 |
"Encoding (ACE)\\ » avant d'être transférées aux fonctions de résolution de " |
| 651 |
"noms." |
| 652 |
|
| 653 |
#. type: TP |
| 654 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 655 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 656 |
#, no-wrap |
| 657 |
msgid "B<AI_CANONIDN>" |
| 658 |
msgstr "B<AI_CANONIDN>" |
| 659 |
|
| 660 |
#. type: Plain text |
| 661 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 662 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 663 |
msgid "" |
| 664 |
"After a successful name lookup, and if the B<AI_CANONNAME> flag was " |
| 665 |
"specified, B<getaddrinfo>() will return the canonical name of the node " |
| 666 |
"corresponding to the I<addrinfo> structure value passed back. The return " |
| 667 |
"value is an exact copy of the value returned by the name resolution function." |
| 668 |
msgstr "" |
| 669 |
"À la suite d'une résolution de nom réussie et si B<AI_CANONNAME> a été " |
| 670 |
"indiqué, B<getaddrinfo>() retournera le nom canonique du nœud correspondant " |
| 671 |
"à la valeur de la structure I<addrinfo> passée. La valeur renvoyée est une " |
| 672 |
"copie exacte de la valeur retournée par la fonction de résolution de noms." |
| 673 |
|
| 674 |
# |
| 675 |
#. Implementation Detail: |
| 676 |
#. If no component of the returned name starts with xn\-\- the IDN |
| 677 |
#. step can be skipped, therefore avoiding unnecessary slowdowns. |
| 678 |
#. type: Plain text |
| 679 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 680 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 681 |
msgid "" |
| 682 |
"If the name is encoded using ACE, then it will contain the I<xn--> prefix " |
| 683 |
"for one or more components of the name. To convert these components into a " |
| 684 |
"readable form the B<AI_CANONIDN> flag can be passed in addition to " |
| 685 |
"B<AI_CANONNAME>. The resulting string is encoded using the current locale's " |
| 686 |
"encoding." |
| 687 |
msgstr "" |
| 688 |
"Si le nom est encodé avec ACE, alors une ou plusieurs composantes de son nom " |
| 689 |
"sont préfixées par I<xn-->. Pour convertir ces composantes dans un format " |
| 690 |
"lisible, l'attribut B<AI_CANONIDN> peut être utilisé en plus de " |
| 691 |
"B<AI_CANONNAME>. La chaîne résultante est encodée selon la locale du système." |
| 692 |
|
| 693 |
#. type: TP |
| 694 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 695 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 696 |
#, no-wrap |
| 697 |
msgid "B<AI_IDN_ALLOW_UNASSIGNED>" |
| 698 |
msgstr "B<AI_IDN_ALLOW_UNASSIGNED>" |
| 699 |
|
| 700 |
#. type: TQ |
| 701 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 702 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 703 |
#, no-wrap |
| 704 |
msgid "B<AI_IDN_USE_STD3_ASCII_RULES>" |
| 705 |
msgstr "B<AI_IDN_USE_STD3_ASCII_RULES>" |
| 706 |
|
| 707 |
#. type: Plain text |
| 708 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 709 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 710 |
msgid "" |
| 711 |
"Setting these flags will enable the IDNA_ALLOW_UNASSIGNED (allow unassigned " |
| 712 |
"Unicode code points) and IDNA_USE_STD3_ASCII_RULES (check output to make " |
| 713 |
"sure it is a STD3 conforming hostname) flags respectively to be used in the " |
| 714 |
"IDNA handling." |
| 715 |
msgstr "" |
| 716 |
"Utiliser ces attributs permet d'activer respectivement les attributs «\\ " |
| 717 |
"IDNA_ALLOW_UNASSIGNED\\ » (permettre des caractères Unicode non assignés) et " |
| 718 |
"«\\ IDNA_USE_STD3_ASCII_RULES\\ » (vérifier la sortie pour être sûr que le " |
| 719 |
"nom d'hôte est conforme à STD3) utilisés dans la gestion de l'IDNA." |
| 720 |
|
| 721 |
#. type: SH |
| 722 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 723 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 724 |
#, no-wrap |
| 725 |
msgid "RETURN VALUE" |
| 726 |
msgstr "VALEUR RENVOYÉE" |
| 727 |
|
| 728 |
#. FIXME glibc defines the following additional errors, some which |
| 729 |
#. can probably be returned by getaddrinfo(); they need to |
| 730 |
#. be documented. |
| 731 |
#. #ifdef __USE_GNU |
| 732 |
#. #define EAI_INPROGRESS -100 /* Processing request in progress. */ |
| 733 |
#. #define EAI_CANCELED -101 /* Request canceled. */ |
| 734 |
#. #define EAI_NOTCANCELED -102 /* Request not canceled. */ |
| 735 |
#. #define EAI_ALLDONE -103 /* All requests done. */ |
| 736 |
#. #define EAI_INTR -104 /* Interrupted by a signal. */ |
| 737 |
#. #define EAI_IDN_ENCODE -105 /* IDN encoding failed. */ |
| 738 |
#. #endif |
| 739 |
#. type: Plain text |
| 740 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 741 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 742 |
msgid "" |
| 743 |
"B<getaddrinfo>() returns 0 if it succeeds, or one of the following nonzero " |
| 744 |
"error codes:" |
| 745 |
msgstr "" |
| 746 |
"B<getaddrinfo>() renvoie B<0> si elle réussit, ou l'un des codes d'erreur " |
| 747 |
"différent de suivants\\ :" |
| 748 |
|
| 749 |
#. type: TP |
| 750 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 751 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 752 |
#, no-wrap |
| 753 |
msgid "B<EAI_ADDRFAMILY>" |
| 754 |
msgstr "B<EAI_ADDRFAMILY>" |
| 755 |
|
| 756 |
#. Not in SUSv3 |
| 757 |
#. type: Plain text |
| 758 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 759 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 760 |
msgid "" |
| 761 |
"The specified network host does not have any network addresses in the " |
| 762 |
"requested address family." |
| 763 |
msgstr "L'hôte indiqué n'a pas d'adresse dans la famille réseau demandée." |
| 764 |
|
| 765 |
#. type: TP |
| 766 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 767 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 768 |
#, no-wrap |
| 769 |
msgid "B<EAI_AGAIN>" |
| 770 |
msgstr "B<EAI_AGAIN>" |
| 771 |
|
| 772 |
#. type: Plain text |
| 773 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 774 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 775 |
msgid "" |
| 776 |
"The name server returned a temporary failure indication. Try again later." |
| 777 |
msgstr "" |
| 778 |
"Le serveur de noms a renvoyé une erreur temporaire. Réessayez plus tard." |
| 779 |
|
| 780 |
#. type: TP |
| 781 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 782 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 783 |
#, no-wrap |
| 784 |
msgid "B<EAI_BADFLAGS>" |
| 785 |
msgstr "B<EAI_BADFLAGS>" |
| 786 |
|
| 787 |
#. type: Plain text |
| 788 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 789 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 790 |
msgid "" |
| 791 |
"I<hints.ai_flags> contains invalid flags; or, I<hints.ai_flags> included " |
| 792 |
"B<AI_CANONNAME> and I<node> was NULL." |
| 793 |
msgstr "" |
| 794 |
"I<hints.ai_flags> contient des drapeaux incorrects ; ou I<hints.ai_flags> " |
| 795 |
"inclut B<AI_CANONNAME> et I<node> est NULL." |
| 796 |
|
| 797 |
#. type: TP |
| 798 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 799 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 800 |
#, no-wrap |
| 801 |
msgid "B<EAI_FAIL>" |
| 802 |
msgstr "B<EAI_FAIL>" |
| 803 |
|
| 804 |
#. type: Plain text |
| 805 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 806 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 807 |
msgid "The name server returned a permanent failure indication." |
| 808 |
msgstr "Le serveur de noms a renvoyé une erreur définitive." |
| 809 |
|
| 810 |
#. type: TP |
| 811 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 812 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 813 |
#, no-wrap |
| 814 |
msgid "B<EAI_FAMILY>" |
| 815 |
msgstr "B<EAI_FAMILY>" |
| 816 |
|
| 817 |
#. type: Plain text |
| 818 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 819 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 820 |
msgid "The requested address family is not supported." |
| 821 |
msgstr "La famille d'adresse réclamée n'est pas supportée." |
| 822 |
|
| 823 |
#. type: TP |
| 824 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 825 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 826 |
#, no-wrap |
| 827 |
msgid "B<EAI_MEMORY>" |
| 828 |
msgstr "B<EAI_MEMORY>" |
| 829 |
|
| 830 |
#. type: Plain text |
| 831 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 832 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 833 |
msgid "Out of memory." |
| 834 |
msgstr "Plus assez de mémoire." |
| 835 |
|
| 836 |
#. type: TP |
| 837 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 838 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 839 |
#, no-wrap |
| 840 |
msgid "B<EAI_NODATA>" |
| 841 |
msgstr "B<EAI_NODATA>" |
| 842 |
|
| 843 |
#. Not in SUSv3 |
| 844 |
#. type: Plain text |
| 845 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 846 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 847 |
msgid "" |
| 848 |
"The specified network host exists, but does not have any network addresses " |
| 849 |
"defined." |
| 850 |
msgstr "L'hôte existe mais n'a pas d'adresse réseau définie." |
| 851 |
|
| 852 |
#. type: TP |
| 853 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 854 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 855 |
#, no-wrap |
| 856 |
msgid "B<EAI_NONAME>" |
| 857 |
msgstr "B<EAI_NONAME>" |
| 858 |
|
| 859 |
#. type: Plain text |
| 860 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 861 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 862 |
msgid "" |
| 863 |
"The I<node> or I<service> is not known; or both I<node> and I<service> are " |
| 864 |
"NULL; or B<AI_NUMERICSERV> was specified in I<hints.ai_flags> and I<service> " |
| 865 |
"was not a numeric port-number string." |
| 866 |
msgstr "" |
| 867 |
"I<node> ou I<service> sont inconnus ou ils sont tous les deux NULL\\ ; ou " |
| 868 |
"B<AI_NUMERICSERV> a été indiqué dans I<hints.ai_flags> mais I<service> n'est " |
| 869 |
"pas un numéro de port." |
| 870 |
|
| 871 |
#. type: TP |
| 872 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 873 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 874 |
#, no-wrap |
| 875 |
msgid "B<EAI_SERVICE>" |
| 876 |
msgstr "B<EAI_SERVICE>" |
| 877 |
|
| 878 |
#. type: Plain text |
| 879 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 880 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 881 |
msgid "" |
| 882 |
"The requested service is not available for the requested socket type. It " |
| 883 |
"may be available through another socket type. For example, this error could " |
| 884 |
"occur if I<service> was \"shell\" (a service available only on stream " |
| 885 |
"sockets), and either I<hints.ai_protocol> was B<IPPROTO_UDP>, or " |
| 886 |
"I<hints.ai_socktype> was B<SOCK_DGRAM>; or the error could occur if " |
| 887 |
"I<service> was not NULL, and I<hints.ai_socktype> was B<SOCK_RAW> (a socket " |
| 888 |
"type that does not support the concept of services)." |
| 889 |
msgstr "" |
| 890 |
"Le service demandé n'est pas disponible pour le type de socket demandé. Il " |
| 891 |
"est probablement disponible avec un autre type de socket. Par exemple, cette " |
| 892 |
"erreur peut se produire si I<service> est «\\ shell\\ » (un service " |
| 893 |
"uniquement disponible avec les sockets de type flux), et soit si " |
| 894 |
"I<hints.ai_protocol> est égal à B<IPPROTO_UDP> ou soit si " |
| 895 |
"I<hints.ai_socktype> est égal à B<SOCK_DGRAM>. L'erreur peut aussi se " |
| 896 |
"produire si I<service> est non NULL et I<hints.ai_socktype> est égal à " |
| 897 |
"B<SOCK_RAW> (un type de socket qui ne gère pas le concept de service)." |
| 898 |
|
| 899 |
#. type: TP |
| 900 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 901 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 902 |
#, no-wrap |
| 903 |
msgid "B<EAI_SOCKTYPE>" |
| 904 |
msgstr "B<EAI_SOCKTYPE>" |
| 905 |
|
| 906 |
#. type: Plain text |
| 907 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 908 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 909 |
msgid "" |
| 910 |
"The requested socket type is not supported. This could occur, for example, " |
| 911 |
"if I<hints.ai_socktype> and I<hints.ai_protocol> are inconsistent (e.g., " |
| 912 |
"B<SOCK_DGRAM> and B<IPPROTO_TCP>, respectively)." |
| 913 |
msgstr "" |
| 914 |
"Le type de socket demandé n'est pas géré. Cela peut se produire, par exemple " |
| 915 |
"si I<hints.ai_socktype> et I<hints.ai_protocol> sont inconsistants (par " |
| 916 |
"exemple, B<SOCK_DGRAM> et B<IPPROTO_TCP>, respectivement)." |
| 917 |
|
| 918 |
#. type: TP |
| 919 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 920 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 921 |
#, no-wrap |
| 922 |
msgid "B<EAI_SYSTEM>" |
| 923 |
msgstr "B<EAI_SYSTEM>" |
| 924 |
|
| 925 |
#. type: Plain text |
| 926 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 927 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 928 |
msgid "Other system error; I<errno> is set to indicate the error." |
| 929 |
msgstr "" |
| 930 |
"Autre erreur système, la valeur de retour est B<-1> et I<errno> est défini " |
| 931 |
"pour indiquer l'erreur." |
| 932 |
|
| 933 |
#. type: Plain text |
| 934 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 935 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 936 |
msgid "" |
| 937 |
"The B<gai_strerror>() function translates these error codes to a human " |
| 938 |
"readable string, suitable for error reporting." |
| 939 |
msgstr "" |
| 940 |
"La fonction B<gai_strerror>() traduit ces codes d'erreur en une chaîne de " |
| 941 |
"caractères compréhensible, utilisable pour rendre compte du problème." |
| 942 |
|
| 943 |
#. type: SH |
| 944 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 945 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 946 |
#, no-wrap |
| 947 |
msgid "FILES" |
| 948 |
msgstr "FICHIERS" |
| 949 |
|
| 950 |
#. type: Plain text |
| 951 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 952 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 953 |
msgid "I</etc/gai.conf>" |
| 954 |
msgstr "I</etc/gai.conf>" |
| 955 |
|
| 956 |
#. type: SH |
| 957 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 958 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 959 |
#, no-wrap |
| 960 |
msgid "ATTRIBUTES" |
| 961 |
msgstr "ATTRIBUTS" |
| 962 |
|
| 963 |
#. type: Plain text |
| 964 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 965 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 966 |
msgid "" |
| 967 |
"For an explanation of the terms used in this section, see B<attributes>(7)." |
| 968 |
msgstr "" |
| 969 |
"Pour une explication des termes utilisés dans cette section, consulter " |
| 970 |
"B<attributes>(7)." |
| 971 |
|
| 972 |
#. type: tbl table |
| 973 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 974 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 975 |
#, no-wrap |
| 976 |
msgid "Interface" |
| 977 |
msgstr "Interface" |
| 978 |
|
| 979 |
#. type: tbl table |
| 980 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 981 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 982 |
#, no-wrap |
| 983 |
msgid "Attribute" |
| 984 |
msgstr "Attribut" |
| 985 |
|
| 986 |
#. type: tbl table |
| 987 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 988 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 989 |
#, no-wrap |
| 990 |
msgid "Value" |
| 991 |
msgstr "Valeur" |
| 992 |
|
| 993 |
#. type: tbl table |
| 994 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 995 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 996 |
#, no-wrap |
| 997 |
msgid ".na\n" |
| 998 |
msgstr ".na\n" |
| 999 |
|
| 1000 |
#. type: tbl table |
| 1001 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1002 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1003 |
#, no-wrap |
| 1004 |
msgid ".nh\n" |
| 1005 |
msgstr ".nh\n" |
| 1006 |
|
| 1007 |
#. type: TP |
| 1008 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1009 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1010 |
#, no-wrap |
| 1011 |
msgid "B<getaddrinfo>()" |
| 1012 |
msgstr "B<getaddrinfo>()" |
| 1013 |
|
| 1014 |
#. type: tbl table |
| 1015 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1016 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1017 |
#, no-wrap |
| 1018 |
msgid "Thread safety" |
| 1019 |
msgstr "Sécurité des threads" |
| 1020 |
|
| 1021 |
#. type: tbl table |
| 1022 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1023 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1024 |
#, no-wrap |
| 1025 |
msgid "MT-Safe env locale" |
| 1026 |
msgstr "MT-Safe env locale" |
| 1027 |
|
| 1028 |
#. type: tbl table |
| 1029 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1030 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1031 |
#, no-wrap |
| 1032 |
msgid "" |
| 1033 |
"B<freeaddrinfo>(),\n" |
| 1034 |
"B<gai_strerror>()" |
| 1035 |
msgstr "" |
| 1036 |
"B<freeaddrinfo>(),\n" |
| 1037 |
"B<gai_strerror>()" |
| 1038 |
|
| 1039 |
#. type: tbl table |
| 1040 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1041 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1042 |
#, no-wrap |
| 1043 |
msgid "MT-Safe" |
| 1044 |
msgstr "MT-Safe" |
| 1045 |
|
| 1046 |
#. type: SH |
| 1047 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1048 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1049 |
#, no-wrap |
| 1050 |
msgid "VERSIONS" |
| 1051 |
msgstr "VERSIONS" |
| 1052 |
|
| 1053 |
#. POSIX.1-2001, POSIX.1-2008 |
| 1054 |
#. type: Plain text |
| 1055 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1056 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1057 |
msgid "" |
| 1058 |
"According to POSIX.1, specifying I<hints> as NULL should cause I<ai_flags> " |
| 1059 |
"to be assumed as 0. The GNU C library instead assumes a value of " |
| 1060 |
"B<(AI_V4MAPPED\\ |\\ AI_ADDRCONFIG)> for this case, since this value is " |
| 1061 |
"considered an improvement on the specification." |
| 1062 |
msgstr "" |
| 1063 |
"Selon POSIX.1, définir I<hints> comme NULL devrait supposer que I<ai_flags> " |
| 1064 |
"soit égal à B<0>. La bibliothèque C de GNU suppose à la place que " |
| 1065 |
"I<ai_flags> est égal à B<(AI_V4MAPPED\\ |\\ AI_ADDRCONFIG)> dans ce cas, " |
| 1066 |
"puisque cette valeur est considérée comme une amélioration de la " |
| 1067 |
"spécification." |
| 1068 |
|
| 1069 |
#. type: SH |
| 1070 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1071 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1072 |
#, no-wrap |
| 1073 |
msgid "STANDARDS" |
| 1074 |
msgstr "NORMES" |
| 1075 |
|
| 1076 |
#. type: Plain text |
| 1077 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1078 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1079 |
msgid "POSIX.1-2008." |
| 1080 |
msgstr "POSIX.1-2008." |
| 1081 |
|
| 1082 |
#. type: Plain text |
| 1083 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1084 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1085 |
msgid "RFC\\ 2553." |
| 1086 |
msgstr "RFC\\ 2553." |
| 1087 |
|
| 1088 |
#. type: SH |
| 1089 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1090 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1091 |
#, no-wrap |
| 1092 |
msgid "HISTORY" |
| 1093 |
msgstr "HISTORIQUE" |
| 1094 |
|
| 1095 |
#. type: Plain text |
| 1096 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1097 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1098 |
msgid "POSIX.1-2001." |
| 1099 |
msgstr "POSIX.1-2001." |
| 1100 |
|
| 1101 |
#. type: TP |
| 1102 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1103 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1104 |
#, no-wrap |
| 1105 |
msgid "B<AI_ADDRCONFIG>" |
| 1106 |
msgstr "B<AI_ADDRCONFIG>" |
| 1107 |
|
| 1108 |
#. type: TQ |
| 1109 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1110 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1111 |
#, no-wrap |
| 1112 |
msgid "B<AI_ALL>" |
| 1113 |
msgstr "B<AI_ALL>" |
| 1114 |
|
| 1115 |
#. type: TQ |
| 1116 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1117 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1118 |
#, no-wrap |
| 1119 |
msgid "B<AI_V4MAPPED>" |
| 1120 |
msgstr "B<AI_V4MAPPED>" |
| 1121 |
|
| 1122 |
#. type: Plain text |
| 1123 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1124 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1125 |
msgid "glibc 2.3.3." |
| 1126 |
msgstr "glibc 2.3.3." |
| 1127 |
|
| 1128 |
#. type: TP |
| 1129 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1130 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1131 |
#, no-wrap |
| 1132 |
msgid "B<AI_NUMERICSERV>" |
| 1133 |
msgstr "B<AI_NUMERICSERV>" |
| 1134 |
|
| 1135 |
#. type: Plain text |
| 1136 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1137 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1138 |
msgid "glibc 2.3.4." |
| 1139 |
msgstr "glibc 2.3.4." |
| 1140 |
|
| 1141 |
#. type: SH |
| 1142 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1143 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1144 |
#, no-wrap |
| 1145 |
msgid "NOTES" |
| 1146 |
msgstr "NOTES" |
| 1147 |
|
| 1148 |
#. type: Plain text |
| 1149 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1150 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1151 |
msgid "" |
| 1152 |
"B<getaddrinfo>() supports the I<address>B<%>I<scope-id> notation for " |
| 1153 |
"specifying the IPv6 scope-ID." |
| 1154 |
msgstr "" |
| 1155 |
"B<getaddrinfo>() gère la notation I<address>B<%>I<scope-id> pour indiquer " |
| 1156 |
"l'identifiant scope de IPv6." |
| 1157 |
|
| 1158 |
#. type: SH |
| 1159 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1160 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1161 |
#, no-wrap |
| 1162 |
msgid "EXAMPLES" |
| 1163 |
msgstr "EXEMPLES" |
| 1164 |
|
| 1165 |
#. getnameinfo.3 refers to this example |
| 1166 |
#. socket.2 refers to this example |
| 1167 |
#. bind.2 refers to this example |
| 1168 |
#. connect.2 refers to this example |
| 1169 |
#. recvfrom.2 refers to this example |
| 1170 |
#. sendto.2 refers to this example |
| 1171 |
#. type: Plain text |
| 1172 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1173 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1174 |
msgid "" |
| 1175 |
"The following programs demonstrate the use of B<getaddrinfo>(), " |
| 1176 |
"B<gai_strerror>(), B<freeaddrinfo>(), and B<getnameinfo>(3). The programs " |
| 1177 |
"are an echo server and client for UDP datagrams." |
| 1178 |
msgstr "" |
| 1179 |
"Le programme suivant explique l'utilisation de B<getaddrinfo>(), " |
| 1180 |
"B<gai_strerror>(), B<freeaddrinfo>(), et B<getnameinfo>(3). Les programmes " |
| 1181 |
"sont des clients et serveurs pour les datagrammes UDP." |
| 1182 |
|
| 1183 |
#. type: SS |
| 1184 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1185 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1186 |
#, no-wrap |
| 1187 |
msgid "Server program" |
| 1188 |
msgstr "Programme du serveur" |
| 1189 |
|
| 1190 |
#. type: Plain text |
| 1191 |
#: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1 |
| 1192 |
#: opensuse-tumbleweed |
| 1193 |
#, fuzzy, no-wrap |
| 1194 |
#| msgid "" |
| 1195 |
#| "#include E<lt>netdb.hE<gt>\n" |
| 1196 |
#| "#include E<lt>stdio.hE<gt>\n" |
| 1197 |
#| "#include E<lt>stdlib.hE<gt>\n" |
| 1198 |
#| "#include E<lt>string.hE<gt>\n" |
| 1199 |
#| "#include E<lt>sys/socket.hE<gt>\n" |
| 1200 |
#| "#include E<lt>sys/types.hE<gt>\n" |
| 1201 |
#| "#include E<lt>unistd.hE<gt>\n" |
| 1202 |
#| "\\&\n" |
| 1203 |
#| "#define BUF_SIZE 500\n" |
| 1204 |
#| "\\&\n" |
| 1205 |
#| "int\n" |
| 1206 |
#| "main(int argc, char *argv[])\n" |
| 1207 |
#| "{\n" |
| 1208 |
#| " int sfd, s;\n" |
| 1209 |
#| " char buf[BUF_SIZE];\n" |
| 1210 |
#| " ssize_t nread;\n" |
| 1211 |
#| " socklen_t peer_addrlen;\n" |
| 1212 |
#| " struct addrinfo hints;\n" |
| 1213 |
#| " struct addrinfo *result, *rp;\n" |
| 1214 |
#| " struct sockaddr_storage peer_addr;\n" |
| 1215 |
#| "\\&\n" |
| 1216 |
#| " if (argc != 2) {\n" |
| 1217 |
#| " fprintf(stderr, \"Usage: %s port\\[rs]n\", argv[0]);\n" |
| 1218 |
#| " exit(EXIT_FAILURE);\n" |
| 1219 |
#| " }\n" |
| 1220 |
#| "\\&\n" |
| 1221 |
#| " memset(&hints, 0, sizeof(hints));\n" |
| 1222 |
#| " hints.ai_family = AF_UNSPEC; /* Allow IPv4 or IPv6 */\n" |
| 1223 |
#| " hints.ai_socktype = SOCK_DGRAM; /* Datagram socket */\n" |
| 1224 |
#| " hints.ai_flags = AI_PASSIVE; /* For wildcard IP address */\n" |
| 1225 |
#| " hints.ai_protocol = 0; /* Any protocol */\n" |
| 1226 |
#| " hints.ai_canonname = NULL;\n" |
| 1227 |
#| " hints.ai_addr = NULL;\n" |
| 1228 |
#| " hints.ai_next = NULL;\n" |
| 1229 |
#| "\\&\n" |
| 1230 |
#| " s = getaddrinfo(NULL, argv[1], &hints, &result);\n" |
| 1231 |
#| " if (s != 0) {\n" |
| 1232 |
#| " fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1233 |
#| " exit(EXIT_FAILURE);\n" |
| 1234 |
#| " }\n" |
| 1235 |
#| "\\&\n" |
| 1236 |
#| " /* getaddrinfo() returns a list of address structures.\n" |
| 1237 |
#| " Try each address until we successfully bind(2).\n" |
| 1238 |
#| " If socket(2) (or bind(2)) fails, we (close the socket\n" |
| 1239 |
#| " and) try the next address. */\n" |
| 1240 |
#| "\\&\n" |
| 1241 |
#| " for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 1242 |
#| " sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 1243 |
#| " rp-E<gt>ai_protocol);\n" |
| 1244 |
#| " if (sfd == -1)\n" |
| 1245 |
#| " continue;\n" |
| 1246 |
#| "\\&\n" |
| 1247 |
#| " if (bind(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) == 0)\n" |
| 1248 |
#| " break; /* Success */\n" |
| 1249 |
#| "\\&\n" |
| 1250 |
#| " close(sfd);\n" |
| 1251 |
#| " }\n" |
| 1252 |
#| "\\&\n" |
| 1253 |
#| " freeaddrinfo(result); /* No longer needed */\n" |
| 1254 |
#| "\\&\n" |
| 1255 |
#| " if (rp == NULL) { /* No address succeeded */\n" |
| 1256 |
#| " fprintf(stderr, \"Could not bind\\[rs]n\");\n" |
| 1257 |
#| " exit(EXIT_FAILURE);\n" |
| 1258 |
#| " }\n" |
| 1259 |
#| "\\&\n" |
| 1260 |
#| " /* Read datagrams and echo them back to sender. */\n" |
| 1261 |
#| "\\&\n" |
| 1262 |
#| " for (;;) {\n" |
| 1263 |
#| " char host[NI_MAXHOST], service[NI_MAXSERV];\n" |
| 1264 |
#| "\\&\n" |
| 1265 |
#| " peer_addrlen = sizeof(peer_addr);\n" |
| 1266 |
#| " nread = recvfrom(sfd, buf, BUF_SIZE, 0,\n" |
| 1267 |
#| " (struct sockaddr *) &peer_addr, &peer_addrlen);\n" |
| 1268 |
#| " if (nread == -1)\n" |
| 1269 |
#| " continue; /* Ignore failed request */\n" |
| 1270 |
#| "\\&\n" |
| 1271 |
#| " s = getnameinfo((struct sockaddr *) &peer_addr,\n" |
| 1272 |
#| " peer_addrlen, host, NI_MAXHOST,\n" |
| 1273 |
#| " service, NI_MAXSERV, NI_NUMERICSERV);\n" |
| 1274 |
#| " if (s == 0)\n" |
| 1275 |
#| " printf(\"Received %zd bytes from %s:%s\\[rs]n\",\n" |
| 1276 |
#| " nread, host, service);\n" |
| 1277 |
#| " else\n" |
| 1278 |
#| " fprintf(stderr, \"getnameinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1279 |
#| "\\&\n" |
| 1280 |
#| " if (sendto(sfd, buf, nread, 0, (struct sockaddr *) &peer_addr,\n" |
| 1281 |
#| " peer_addrlen) != nread)\n" |
| 1282 |
#| " {\n" |
| 1283 |
#| " fprintf(stderr, \"Error sending response\\[rs]n\");\n" |
| 1284 |
#| " }\n" |
| 1285 |
#| " }\n" |
| 1286 |
#| "}\n" |
| 1287 |
msgid "" |
| 1288 |
"#include E<lt>netdb.hE<gt>\n" |
| 1289 |
"#include E<lt>stdio.hE<gt>\n" |
| 1290 |
"#include E<lt>stdlib.hE<gt>\n" |
| 1291 |
"#include E<lt>string.hE<gt>\n" |
| 1292 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 1293 |
"#include E<lt>sys/types.hE<gt>\n" |
| 1294 |
"#include E<lt>unistd.hE<gt>\n" |
| 1295 |
"\\&\n" |
| 1296 |
"#define BUF_SIZE 500\n" |
| 1297 |
"\\&\n" |
| 1298 |
"int\n" |
| 1299 |
"main(int argc, char *argv[])\n" |
| 1300 |
"{\n" |
| 1301 |
" int sfd, s;\n" |
| 1302 |
" char buf[BUF_SIZE];\n" |
| 1303 |
" ssize_t nread;\n" |
| 1304 |
" socklen_t peer_addrlen;\n" |
| 1305 |
" struct addrinfo hints;\n" |
| 1306 |
" struct addrinfo *result, *rp;\n" |
| 1307 |
" struct sockaddr_storage peer_addr;\n" |
| 1308 |
"\\&\n" |
| 1309 |
" if (argc != 2) {\n" |
| 1310 |
" fprintf(stderr, \"Usage: %s port\\[rs]n\", argv[0]);\n" |
| 1311 |
" exit(EXIT_FAILURE);\n" |
| 1312 |
" }\n" |
| 1313 |
"\\&\n" |
| 1314 |
" memset(&hints, 0, sizeof(hints));\n" |
| 1315 |
" hints.ai_family = AF_UNSPEC; /* Allow IPv4 or IPv6 */\n" |
| 1316 |
" hints.ai_socktype = SOCK_DGRAM; /* Datagram socket */\n" |
| 1317 |
" hints.ai_flags = AI_PASSIVE; /* For wildcard IP address */\n" |
| 1318 |
" hints.ai_protocol = 0; /* Any protocol */\n" |
| 1319 |
" hints.ai_canonname = NULL;\n" |
| 1320 |
" hints.ai_addr = NULL;\n" |
| 1321 |
" hints.ai_next = NULL;\n" |
| 1322 |
"\\&\n" |
| 1323 |
" s = getaddrinfo(NULL, argv[1], &hints, &result);\n" |
| 1324 |
" if (s != 0) {\n" |
| 1325 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1326 |
" exit(EXIT_FAILURE);\n" |
| 1327 |
" }\n" |
| 1328 |
"\\&\n" |
| 1329 |
" /* getaddrinfo() returns a list of address structures.\n" |
| 1330 |
" Try each address until we successfully bind(2).\n" |
| 1331 |
" If socket(2) (or bind(2)) fails, we (close the socket\n" |
| 1332 |
" and) try the next address. */\n" |
| 1333 |
"\\&\n" |
| 1334 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 1335 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 1336 |
" rp-E<gt>ai_protocol);\n" |
| 1337 |
" if (sfd == -1)\n" |
| 1338 |
" continue;\n" |
| 1339 |
"\\&\n" |
| 1340 |
" if (bind(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) == 0)\n" |
| 1341 |
" break; /* Success */\n" |
| 1342 |
"\\&\n" |
| 1343 |
" close(sfd);\n" |
| 1344 |
" }\n" |
| 1345 |
"\\&\n" |
| 1346 |
" freeaddrinfo(result); /* No longer needed */\n" |
| 1347 |
"\\&\n" |
| 1348 |
" if (rp == NULL) { /* No address succeeded */\n" |
| 1349 |
" fprintf(stderr, \"Could not bind\\[rs]n\");\n" |
| 1350 |
" exit(EXIT_FAILURE);\n" |
| 1351 |
" }\n" |
| 1352 |
"\\&\n" |
| 1353 |
" /* Read datagrams and echo them back to sender. */\n" |
| 1354 |
"\\&\n" |
| 1355 |
" for (;;) {\n" |
| 1356 |
" char host[NI_MAXHOST], service[NI_MAXSERV];\n" |
| 1357 |
"\\&\n" |
| 1358 |
" peer_addrlen = sizeof(peer_addr);\n" |
| 1359 |
" nread = recvfrom(sfd, buf, BUF_SIZE, 0,\n" |
| 1360 |
" (struct sockaddr *) &peer_addr, &peer_addrlen);\n" |
| 1361 |
" if (nread == -1)\n" |
| 1362 |
" continue; /* Ignore failed request */\n" |
| 1363 |
"\\&\n" |
| 1364 |
" s = getnameinfo((struct sockaddr *) &peer_addr,\n" |
| 1365 |
" peer_addrlen, host, NI_MAXHOST,\n" |
| 1366 |
" service, NI_MAXSERV, NI_NUMERICSERV);\n" |
| 1367 |
" if (s == 0)\n" |
| 1368 |
" printf(\"Received %zd bytes from %s:%s\\[rs]n\",\n" |
| 1369 |
" nread, host, service);\n" |
| 1370 |
" else\n" |
| 1371 |
" fprintf(stderr, \"getnameinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1372 |
"\\&\n" |
| 1373 |
" if (sendto(sfd, buf, nread, 0, (struct sockaddr *) &peer_addr,\n" |
| 1374 |
" peer_addrlen) != nread)\n" |
| 1375 |
" {\n" |
| 1376 |
" fprintf(stderr, \"Error sending response\\[rs]n\");\n" |
| 1377 |
" }\n" |
| 1378 |
" }\n" |
| 1379 |
"}\n" |
| 1380 |
msgstr "" |
| 1381 |
"#include E<lt>netdb.hE<gt>\n" |
| 1382 |
"#include E<lt>stdio.hE<gt>\n" |
| 1383 |
"#include E<lt>stdlib.hE<gt>\n" |
| 1384 |
"#include E<lt>string.hE<gt>\n" |
| 1385 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 1386 |
"#include E<lt>sys/types.hE<gt>\n" |
| 1387 |
"#include E<lt>unistd.hE<gt>\n" |
| 1388 |
"\\&\n" |
| 1389 |
"#define BUF_SIZE 500\n" |
| 1390 |
"\\&\n" |
| 1391 |
"int\n" |
| 1392 |
"main(int argc, char *argv[])\n" |
| 1393 |
"{\n" |
| 1394 |
" int sfd, s;\n" |
| 1395 |
" char buf[BUF_SIZE];\n" |
| 1396 |
" ssize_t nread;\n" |
| 1397 |
" socklen_t peer_addrlen;\n" |
| 1398 |
" struct addrinfo hints;\n" |
| 1399 |
" struct addrinfo *result, *rp;\n" |
| 1400 |
" struct sockaddr_storage peer_addr;\n" |
| 1401 |
"\\&\n" |
| 1402 |
" if (argc != 2) {\n" |
| 1403 |
" fprintf(stderr, \"Utilisation : %s port\\[rs]n\", argv[0]);\n" |
| 1404 |
" exit(EXIT_FAILURE);\n" |
| 1405 |
" }\n" |
| 1406 |
"\\&\n" |
| 1407 |
" memset(&hints, 0, sizeof(hints));\n" |
| 1408 |
" hints.ai_family = AF_UNSPEC; /* IPv4 ou IPv6 permis */\n" |
| 1409 |
" hints.ai_socktype = SOCK_DGRAM; /* Socket du datagramme */\n" |
| 1410 |
" hints.ai_flags = AI_PASSIVE; /* Pour une adresse IP joker */\n" |
| 1411 |
" hints.ai_protocol = 0; /* Tout protocole */\n" |
| 1412 |
" hints.ai_canonname = NULL;\n" |
| 1413 |
" hints.ai_addr = NULL;\n" |
| 1414 |
" hints.ai_next = NULL;\n" |
| 1415 |
"\\&\n" |
| 1416 |
" s = getaddrinfo(NULL, argv[1], &hints, &result);\n" |
| 1417 |
" if (s != 0) {\n" |
| 1418 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1419 |
" exit(EXIT_FAILURE);\n" |
| 1420 |
" }\n" |
| 1421 |
"\\&\n" |
| 1422 |
" /* getaddrinfo() renvoie une liste de structures d'adresse.\n" |
| 1423 |
" Essayer cheque adresse jusqu'à un bind(2) réussi.\n" |
| 1424 |
" Si socket(2) (ou bind(2)) échoue, on (clôt le socket\n" |
| 1425 |
" et) essaie l'adresse suivante. */\n" |
| 1426 |
"\\&\n" |
| 1427 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 1428 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 1429 |
" rp-E<gt>ai_protocol);\n" |
| 1430 |
" if (sfd == -1)\n" |
| 1431 |
" continue;\n" |
| 1432 |
"\\&\n" |
| 1433 |
" if (bind(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) == 0)\n" |
| 1434 |
" break; /* Succès */\n" |
| 1435 |
"\\&\n" |
| 1436 |
" close(sfd);\n" |
| 1437 |
" }\n" |
| 1438 |
"\\&\n" |
| 1439 |
" freeaddrinfo(result); /* Plus nécessaire */\n" |
| 1440 |
"\\&\n" |
| 1441 |
" if (rp == NULL) { /* Toutes les adresses ont échoué */\n" |
| 1442 |
" fprintf(stderr, \"Pas de lien créé\\[rs]n\");\n" |
| 1443 |
" exit(EXIT_FAILURE);\n" |
| 1444 |
" }\n" |
| 1445 |
"\\&\n" |
| 1446 |
" /* Lire les datagrammes et les renvoyer à l'envoyeur. */\n" |
| 1447 |
"\\&\n" |
| 1448 |
" for (;;) {\n" |
| 1449 |
" char host[NI_MAXHOST], service[NI_MAXSERV];\n" |
| 1450 |
"\\&\n" |
| 1451 |
" peer_addrlen = sizeof(peer_addr);\n" |
| 1452 |
" nread = recvfrom(sfd, buf, BUF_SIZE, 0,\n" |
| 1453 |
" (struct sockaddr *) &peer_addr, &peer_addrlen);\n" |
| 1454 |
" if (nread == -1)\n" |
| 1455 |
" continue; /* Ignorer la requête en échec */\n" |
| 1456 |
"\\&\n" |
| 1457 |
" s = getnameinfo((struct sockaddr *) &peer_addr,\n" |
| 1458 |
" peer_addrlen, host, NI_MAXHOST,\n" |
| 1459 |
" service, NI_MAXSERV, NI_NUMERICSERV);\n" |
| 1460 |
" if (s == 0)\n" |
| 1461 |
" printf(\"%zd octets reçus de %s:%s\\[rs]n\",\n" |
| 1462 |
" nread, host, service);\n" |
| 1463 |
" else\n" |
| 1464 |
" fprintf(stderr, \"getnameinfo : %s\\[rs]n\", gai_strerror(s));\n" |
| 1465 |
"\\&\n" |
| 1466 |
" if (sendto(sfd, buf, nread, 0, (struct sockaddr *) &peer_addr,\n" |
| 1467 |
" peer_addrlen) != nread)\n" |
| 1468 |
" {\n" |
| 1469 |
" fprintf(stderr, \"Erreur d'envoi de réponse\\[rs]n\");\n" |
| 1470 |
" }\n" |
| 1471 |
" }\n" |
| 1472 |
"}\n" |
| 1473 |
|
| 1474 |
# NOTE: .R " " not supported by po4a |
| 1475 |
#. SRC END |
| 1476 |
#. type: SS |
| 1477 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1478 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1479 |
#, no-wrap |
| 1480 |
msgid "Client program" |
| 1481 |
msgstr "Programme du client" |
| 1482 |
|
| 1483 |
#. type: Plain text |
| 1484 |
#: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1 |
| 1485 |
#: opensuse-tumbleweed |
| 1486 |
#, fuzzy, no-wrap |
| 1487 |
#| msgid "" |
| 1488 |
#| "#include E<lt>netdb.hE<gt>\n" |
| 1489 |
#| "#include E<lt>stdio.hE<gt>\n" |
| 1490 |
#| "#include E<lt>stdlib.hE<gt>\n" |
| 1491 |
#| "#include E<lt>string.hE<gt>\n" |
| 1492 |
#| "#include E<lt>sys/socket.hE<gt>\n" |
| 1493 |
#| "#include E<lt>sys/types.hE<gt>\n" |
| 1494 |
#| "#include E<lt>unistd.hE<gt>\n" |
| 1495 |
#| "\\&\n" |
| 1496 |
#| "#define BUF_SIZE 500\n" |
| 1497 |
#| "\\&\n" |
| 1498 |
#| "int\n" |
| 1499 |
#| "main(int argc, char *argv[])\n" |
| 1500 |
#| "{\n" |
| 1501 |
#| " int sfd, s;\n" |
| 1502 |
#| " char buf[BUF_SIZE];\n" |
| 1503 |
#| " size_t size;\n" |
| 1504 |
#| " ssize_t nread;\n" |
| 1505 |
#| " struct addrinfo hints;\n" |
| 1506 |
#| " struct addrinfo *result, *rp;\n" |
| 1507 |
#| "\\&\n" |
| 1508 |
#| " if (argc E<lt> 3) {\n" |
| 1509 |
#| " fprintf(stderr, \"Usage: %s host port msg...\\[rs]n\", argv[0]);\n" |
| 1510 |
#| " exit(EXIT_FAILURE);\n" |
| 1511 |
#| " }\n" |
| 1512 |
#| "\\&\n" |
| 1513 |
#| " /* Obtain address(es) matching host/port. */\n" |
| 1514 |
#| "\\&\n" |
| 1515 |
#| " memset(&hints, 0, sizeof(hints));\n" |
| 1516 |
#| " hints.ai_family = AF_UNSPEC; /* Allow IPv4 or IPv6 */\n" |
| 1517 |
#| " hints.ai_socktype = SOCK_DGRAM; /* Datagram socket */\n" |
| 1518 |
#| " hints.ai_flags = 0;\n" |
| 1519 |
#| " hints.ai_protocol = 0; /* Any protocol */\n" |
| 1520 |
#| "\\&\n" |
| 1521 |
#| " s = getaddrinfo(argv[1], argv[2], &hints, &result);\n" |
| 1522 |
#| " if (s != 0) {\n" |
| 1523 |
#| " fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1524 |
#| " exit(EXIT_FAILURE);\n" |
| 1525 |
#| " }\n" |
| 1526 |
#| "\\&\n" |
| 1527 |
#| " /* getaddrinfo() returns a list of address structures.\n" |
| 1528 |
#| " Try each address until we successfully connect(2).\n" |
| 1529 |
#| " If socket(2) (or connect(2)) fails, we (close the socket\n" |
| 1530 |
#| " and) try the next address. */\n" |
| 1531 |
#| "\\&\n" |
| 1532 |
#| " for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 1533 |
#| " sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 1534 |
#| " rp-E<gt>ai_protocol);\n" |
| 1535 |
#| " if (sfd == -1)\n" |
| 1536 |
#| " continue;\n" |
| 1537 |
#| "\\&\n" |
| 1538 |
#| " if (connect(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) != -1)\n" |
| 1539 |
#| " break; /* Success */\n" |
| 1540 |
#| "\\&\n" |
| 1541 |
#| " close(sfd);\n" |
| 1542 |
#| " }\n" |
| 1543 |
#| "\\&\n" |
| 1544 |
#| " freeaddrinfo(result); /* No longer needed */\n" |
| 1545 |
#| "\\&\n" |
| 1546 |
#| " if (rp == NULL) { /* No address succeeded */\n" |
| 1547 |
#| " fprintf(stderr, \"Could not connect\\[rs]n\");\n" |
| 1548 |
#| " exit(EXIT_FAILURE);\n" |
| 1549 |
#| " }\n" |
| 1550 |
#| "\\&\n" |
| 1551 |
#| " /* Send remaining command-line arguments as separate\n" |
| 1552 |
#| " datagrams, and read responses from server. */\n" |
| 1553 |
#| "\\&\n" |
| 1554 |
#| " for (size_t j = 3; j E<lt> argc; j++) {\n" |
| 1555 |
#| " size = strlen(argv[j]) + 1;\n" |
| 1556 |
#| " /* +1 for terminating null byte */\n" |
| 1557 |
#| "\\&\n" |
| 1558 |
#| " if (size E<gt> BUF_SIZE) {\n" |
| 1559 |
#| " fprintf(stderr,\n" |
| 1560 |
#| " \"Ignoring long message in argument %zu\\[rs]n\", j);\n" |
| 1561 |
#| " continue;\n" |
| 1562 |
#| " }\n" |
| 1563 |
#| "\\&\n" |
| 1564 |
#| " if (write(sfd, argv[j], size) != size) {\n" |
| 1565 |
#| " fprintf(stderr, \"partial/failed write\\[rs]n\");\n" |
| 1566 |
#| " exit(EXIT_FAILURE);\n" |
| 1567 |
#| " }\n" |
| 1568 |
#| "\\&\n" |
| 1569 |
#| " nread = read(sfd, buf, BUF_SIZE);\n" |
| 1570 |
#| " if (nread == -1) {\n" |
| 1571 |
#| " perror(\"read\");\n" |
| 1572 |
#| " exit(EXIT_FAILURE);\n" |
| 1573 |
#| " }\n" |
| 1574 |
#| "\\&\n" |
| 1575 |
#| " printf(\"Received %zd bytes: %s\\[rs]n\", nread, buf);\n" |
| 1576 |
#| " }\n" |
| 1577 |
#| "\\&\n" |
| 1578 |
#| " exit(EXIT_SUCCESS);\n" |
| 1579 |
#| "}\n" |
| 1580 |
msgid "" |
| 1581 |
"#include E<lt>netdb.hE<gt>\n" |
| 1582 |
"#include E<lt>stdio.hE<gt>\n" |
| 1583 |
"#include E<lt>stdlib.hE<gt>\n" |
| 1584 |
"#include E<lt>string.hE<gt>\n" |
| 1585 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 1586 |
"#include E<lt>sys/types.hE<gt>\n" |
| 1587 |
"#include E<lt>unistd.hE<gt>\n" |
| 1588 |
"\\&\n" |
| 1589 |
"#define BUF_SIZE 500\n" |
| 1590 |
"\\&\n" |
| 1591 |
"int\n" |
| 1592 |
"main(int argc, char *argv[])\n" |
| 1593 |
"{\n" |
| 1594 |
" int sfd, s;\n" |
| 1595 |
" char buf[BUF_SIZE];\n" |
| 1596 |
" size_t size;\n" |
| 1597 |
" ssize_t nread;\n" |
| 1598 |
" struct addrinfo hints;\n" |
| 1599 |
" struct addrinfo *result, *rp;\n" |
| 1600 |
"\\&\n" |
| 1601 |
" if (argc E<lt> 3) {\n" |
| 1602 |
" fprintf(stderr, \"Usage: %s host port msg...\\[rs]n\", argv[0]);\n" |
| 1603 |
" exit(EXIT_FAILURE);\n" |
| 1604 |
" }\n" |
| 1605 |
"\\&\n" |
| 1606 |
" /* Obtain address(es) matching host/port. */\n" |
| 1607 |
"\\&\n" |
| 1608 |
" memset(&hints, 0, sizeof(hints));\n" |
| 1609 |
" hints.ai_family = AF_UNSPEC; /* Allow IPv4 or IPv6 */\n" |
| 1610 |
" hints.ai_socktype = SOCK_DGRAM; /* Datagram socket */\n" |
| 1611 |
" hints.ai_flags = 0;\n" |
| 1612 |
" hints.ai_protocol = 0; /* Any protocol */\n" |
| 1613 |
"\\&\n" |
| 1614 |
" s = getaddrinfo(argv[1], argv[2], &hints, &result);\n" |
| 1615 |
" if (s != 0) {\n" |
| 1616 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1617 |
" exit(EXIT_FAILURE);\n" |
| 1618 |
" }\n" |
| 1619 |
"\\&\n" |
| 1620 |
" /* getaddrinfo() returns a list of address structures.\n" |
| 1621 |
" Try each address until we successfully connect(2).\n" |
| 1622 |
" If socket(2) (or connect(2)) fails, we (close the socket\n" |
| 1623 |
" and) try the next address. */\n" |
| 1624 |
"\\&\n" |
| 1625 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 1626 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 1627 |
" rp-E<gt>ai_protocol);\n" |
| 1628 |
" if (sfd == -1)\n" |
| 1629 |
" continue;\n" |
| 1630 |
"\\&\n" |
| 1631 |
" if (connect(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) != -1)\n" |
| 1632 |
" break; /* Success */\n" |
| 1633 |
"\\&\n" |
| 1634 |
" close(sfd);\n" |
| 1635 |
" }\n" |
| 1636 |
"\\&\n" |
| 1637 |
" freeaddrinfo(result); /* No longer needed */\n" |
| 1638 |
"\\&\n" |
| 1639 |
" if (rp == NULL) { /* No address succeeded */\n" |
| 1640 |
" fprintf(stderr, \"Could not connect\\[rs]n\");\n" |
| 1641 |
" exit(EXIT_FAILURE);\n" |
| 1642 |
" }\n" |
| 1643 |
"\\&\n" |
| 1644 |
" /* Send remaining command-line arguments as separate\n" |
| 1645 |
" datagrams, and read responses from server. */\n" |
| 1646 |
"\\&\n" |
| 1647 |
" for (size_t j = 3; j E<lt> argc; j++) {\n" |
| 1648 |
" size = strlen(argv[j]) + 1;\n" |
| 1649 |
" /* +1 for terminating null byte */\n" |
| 1650 |
"\\&\n" |
| 1651 |
" if (size E<gt> BUF_SIZE) {\n" |
| 1652 |
" fprintf(stderr,\n" |
| 1653 |
" \"Ignoring long message in argument %zu\\[rs]n\", j);\n" |
| 1654 |
" continue;\n" |
| 1655 |
" }\n" |
| 1656 |
"\\&\n" |
| 1657 |
" if (write(sfd, argv[j], size) != size) {\n" |
| 1658 |
" fprintf(stderr, \"partial/failed write\\[rs]n\");\n" |
| 1659 |
" exit(EXIT_FAILURE);\n" |
| 1660 |
" }\n" |
| 1661 |
"\\&\n" |
| 1662 |
" nread = read(sfd, buf, BUF_SIZE);\n" |
| 1663 |
" if (nread == -1) {\n" |
| 1664 |
" perror(\"read\");\n" |
| 1665 |
" exit(EXIT_FAILURE);\n" |
| 1666 |
" }\n" |
| 1667 |
"\\&\n" |
| 1668 |
" printf(\"Received %zd bytes: %s\\[rs]n\", nread, buf);\n" |
| 1669 |
" }\n" |
| 1670 |
"\\&\n" |
| 1671 |
" exit(EXIT_SUCCESS);\n" |
| 1672 |
"}\n" |
| 1673 |
msgstr "" |
| 1674 |
"#include E<lt>netdb.hE<gt>\n" |
| 1675 |
"#include E<lt>stdio.hE<gt>\n" |
| 1676 |
"#include E<lt>stdlib.hE<gt>\n" |
| 1677 |
"#include E<lt>string.hE<gt>\n" |
| 1678 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 1679 |
"#include E<lt>sys/types.hE<gt>\n" |
| 1680 |
"#include E<lt>unistd.hE<gt>\n" |
| 1681 |
"\\&\n" |
| 1682 |
"#define BUF_SIZE 500\n" |
| 1683 |
"\\&\n" |
| 1684 |
"int\n" |
| 1685 |
"main(int argc, char *argv[])\n" |
| 1686 |
"{\n" |
| 1687 |
" int sfd, s;\n" |
| 1688 |
" char buf[BUF_SIZE];\n" |
| 1689 |
" size_t size;\n" |
| 1690 |
" ssize_t nread;\n" |
| 1691 |
" struct addrinfo hints;\n" |
| 1692 |
" struct addrinfo *result, *rp;\n" |
| 1693 |
"\\&\n" |
| 1694 |
" if (argc E<lt> 3) {\n" |
| 1695 |
" fprintf(stderr, \"Utilisation : %s host port msg...\\[rs]n\", argv[0]);\n" |
| 1696 |
" exit(EXIT_FAILURE);\n" |
| 1697 |
" }\n" |
| 1698 |
"\\&\n" |
| 1699 |
" /* Obtenir les adresses correspondantes hôte/port. */\n" |
| 1700 |
"\\&\n" |
| 1701 |
" memset(&hints, 0, sizeof(hints));\n" |
| 1702 |
" hints.ai_family = AF_UNSPEC; /* IPv4 ou IPv6 permis */\n" |
| 1703 |
" hints.ai_socktype = SOCK_DGRAM; /* Socket du datagramme */\n" |
| 1704 |
" hints.ai_flags = 0;\n" |
| 1705 |
" hints.ai_protocol = 0; /* Tout protocole */\n" |
| 1706 |
"\\&\n" |
| 1707 |
" s = getaddrinfo(argv[1], argv[2], &hints, &result);\n" |
| 1708 |
" if (s != 0) {\n" |
| 1709 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1710 |
" exit(EXIT_FAILURE);\n" |
| 1711 |
" }\n" |
| 1712 |
"\\&\n" |
| 1713 |
" /* getaddrinfo() renvoie une liste de structures d'adresse.\n" |
| 1714 |
" Essayer chaque adresse jusqu'à un bind(2) réussi.\n" |
| 1715 |
" Si socket(2) (ou bind(2)) échoue, on (clôt le socket\n" |
| 1716 |
" et) essaie l'adresse suivante. */\n" |
| 1717 |
"\\&\n" |
| 1718 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 1719 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 1720 |
" rp-E<gt>ai_protocol);\n" |
| 1721 |
" if (sfd == -1)\n" |
| 1722 |
" continue;\n" |
| 1723 |
"\\&\n" |
| 1724 |
" if (connect(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) != -1)\n" |
| 1725 |
" break; /* Succès */\n" |
| 1726 |
"\\&\n" |
| 1727 |
" close(sfd);\n" |
| 1728 |
" }\n" |
| 1729 |
"\\&\n" |
| 1730 |
" freeaddrinfo(result); /* Plus nécessaire */\n" |
| 1731 |
"\\&\n" |
| 1732 |
" if (rp == NULL) { /* Toutes les adresses ont échoué */\n" |
| 1733 |
" fprintf(stderr, \"Connexion impossible\\[rs]n\");\n" |
| 1734 |
" exit(EXIT_FAILURE);\n" |
| 1735 |
" }\n" |
| 1736 |
"\\&\n" |
| 1737 |
" /* Envoyer les arguments en ligne de commande comme des datagrammes\n" |
| 1738 |
" séparés et lire les réponses du serveur. */\n" |
| 1739 |
"\\&\n" |
| 1740 |
" for (size_t j = 3; j E<lt> argc; j++) {\n" |
| 1741 |
" size = strlen(argv[j]) + 1;\n" |
| 1742 |
" /* +1 pour l'octet NULL de terminaison */\n" |
| 1743 |
"\\&\n" |
| 1744 |
" if (size E<gt> BUF_SIZE) {\n" |
| 1745 |
" fprintf(stderr,\n" |
| 1746 |
" \"Ignorer le message long dans l'argument %zu\\[rs]n\", j);\n" |
| 1747 |
" continue;\n" |
| 1748 |
" }\n" |
| 1749 |
"\\&\n" |
| 1750 |
" if (write(sfd, argv[j], size) != size) {\n" |
| 1751 |
" fprintf(stderr, \"écriture partielle/échec\\[rs]n\");\n" |
| 1752 |
" exit(EXIT_FAILURE);\n" |
| 1753 |
" }\n" |
| 1754 |
"\\&\n" |
| 1755 |
" nread = read(sfd, buf, BUF_SIZE);\n" |
| 1756 |
" if (nread == -1) {\n" |
| 1757 |
" perror(\"read\");\n" |
| 1758 |
" exit(EXIT_FAILURE);\n" |
| 1759 |
" }\n" |
| 1760 |
"\\&\n" |
| 1761 |
" printf(\"%zd octets reçus de : %s\\[rs]n\", nread, buf);\n" |
| 1762 |
" }\n" |
| 1763 |
"\\&\n" |
| 1764 |
" exit(EXIT_SUCCESS);\n" |
| 1765 |
"}\n" |
| 1766 |
|
| 1767 |
#. SRC END |
| 1768 |
#. type: SH |
| 1769 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1770 |
#: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed |
| 1771 |
#, no-wrap |
| 1772 |
msgid "SEE ALSO" |
| 1773 |
msgstr "VOIR AUSSI" |
| 1774 |
|
| 1775 |
#. .BR getipnodebyaddr (3), |
| 1776 |
#. .BR getipnodebyname (3), |
| 1777 |
#. type: Plain text |
| 1778 |
#: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide |
| 1779 |
#: mageia-cauldron |
| 1780 |
msgid "" |
| 1781 |
"B<getaddrinfo_a>(3), B<gethostbyname>(3), B<getnameinfo>(3), B<inet>(3), " |
| 1782 |
"B<gai.conf>(5), B<hostname>(7), B<ip>(7)" |
| 1783 |
msgstr "" |
| 1784 |
"B<getaddrinfo_a>(3), B<gethostbyname>(3), B<getnameinfo>(3), B<inet>(3), " |
| 1785 |
"B<gai.conf>(5), B<hostname>(7), B<ip>(7)" |
| 1786 |
|
| 1787 |
#. type: TH |
| 1788 |
#: debian-trixie |
| 1789 |
#, no-wrap |
| 1790 |
msgid "2024-06-15" |
| 1791 |
msgstr "15 juin 2024" |
| 1792 |
|
| 1793 |
#. type: TH |
| 1794 |
#: debian-trixie |
| 1795 |
#, no-wrap |
| 1796 |
msgid "Linux man-pages 6.9.1" |
| 1797 |
msgstr "Pages du manuel de Linux 6.9.1" |
| 1798 |
|
| 1799 |
#. type: Plain text |
| 1800 |
#: debian-trixie |
| 1801 |
msgid "Standard C library (I<libc>, I<-lc>)" |
| 1802 |
msgstr "Bibliothèque C standard (I<libc>, I<-lc>)" |
| 1803 |
|
| 1804 |
#. type: Plain text |
| 1805 |
#: debian-trixie |
| 1806 |
msgid "" |
| 1807 |
"A pointer to the socket address is placed in the I<ai_addr> field, and the " |
| 1808 |
"length of the socket address, in bytes, is placed in the I<ai_addrlen> field." |
| 1809 |
msgstr "" |
| 1810 |
"Un pointeur vers l'adresse de la socket est placé dans le champ I<ai_addr>, " |
| 1811 |
"et la longueur de l'adresse de la socket, en octets, est inscrite dans le " |
| 1812 |
"champ I<ai_addrlen> de la structure." |
| 1813 |
|
| 1814 |
#. type: Plain text |
| 1815 |
#: debian-trixie fedora-44 fedora-rawhide |
| 1816 |
#, no-wrap |
| 1817 |
msgid "" |
| 1818 |
"#include E<lt>netdb.hE<gt>\n" |
| 1819 |
"#include E<lt>stdio.hE<gt>\n" |
| 1820 |
"#include E<lt>stdlib.hE<gt>\n" |
| 1821 |
"#include E<lt>string.hE<gt>\n" |
| 1822 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 1823 |
"#include E<lt>sys/types.hE<gt>\n" |
| 1824 |
"#include E<lt>unistd.hE<gt>\n" |
| 1825 |
"\\&\n" |
| 1826 |
"#define BUF_SIZE 500\n" |
| 1827 |
"\\&\n" |
| 1828 |
"int\n" |
| 1829 |
"main(int argc, char *argv[])\n" |
| 1830 |
"{\n" |
| 1831 |
" int sfd, s;\n" |
| 1832 |
" char buf[BUF_SIZE];\n" |
| 1833 |
" ssize_t nread;\n" |
| 1834 |
" socklen_t peer_addrlen;\n" |
| 1835 |
" struct addrinfo hints;\n" |
| 1836 |
" struct addrinfo *result, *rp;\n" |
| 1837 |
" struct sockaddr_storage peer_addr;\n" |
| 1838 |
"\\&\n" |
| 1839 |
" if (argc != 2) {\n" |
| 1840 |
" fprintf(stderr, \"Usage: %s port\\[rs]n\", argv[0]);\n" |
| 1841 |
" exit(EXIT_FAILURE);\n" |
| 1842 |
" }\n" |
| 1843 |
"\\&\n" |
| 1844 |
" memset(&hints, 0, sizeof(hints));\n" |
| 1845 |
" hints.ai_family = AF_UNSPEC; /* Allow IPv4 or IPv6 */\n" |
| 1846 |
" hints.ai_socktype = SOCK_DGRAM; /* Datagram socket */\n" |
| 1847 |
" hints.ai_flags = AI_PASSIVE; /* For wildcard IP address */\n" |
| 1848 |
" hints.ai_protocol = 0; /* Any protocol */\n" |
| 1849 |
" hints.ai_canonname = NULL;\n" |
| 1850 |
" hints.ai_addr = NULL;\n" |
| 1851 |
" hints.ai_next = NULL;\n" |
| 1852 |
"\\&\n" |
| 1853 |
" s = getaddrinfo(NULL, argv[1], &hints, &result);\n" |
| 1854 |
" if (s != 0) {\n" |
| 1855 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1856 |
" exit(EXIT_FAILURE);\n" |
| 1857 |
" }\n" |
| 1858 |
"\\&\n" |
| 1859 |
" /* getaddrinfo() returns a list of address structures.\n" |
| 1860 |
" Try each address until we successfully bind(2).\n" |
| 1861 |
" If socket(2) (or bind(2)) fails, we (close the socket\n" |
| 1862 |
" and) try the next address. */\n" |
| 1863 |
"\\&\n" |
| 1864 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 1865 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 1866 |
" rp-E<gt>ai_protocol);\n" |
| 1867 |
" if (sfd == -1)\n" |
| 1868 |
" continue;\n" |
| 1869 |
"\\&\n" |
| 1870 |
" if (bind(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) == 0)\n" |
| 1871 |
" break; /* Success */\n" |
| 1872 |
"\\&\n" |
| 1873 |
" close(sfd);\n" |
| 1874 |
" }\n" |
| 1875 |
"\\&\n" |
| 1876 |
" freeaddrinfo(result); /* No longer needed */\n" |
| 1877 |
"\\&\n" |
| 1878 |
" if (rp == NULL) { /* No address succeeded */\n" |
| 1879 |
" fprintf(stderr, \"Could not bind\\[rs]n\");\n" |
| 1880 |
" exit(EXIT_FAILURE);\n" |
| 1881 |
" }\n" |
| 1882 |
"\\&\n" |
| 1883 |
" /* Read datagrams and echo them back to sender. */\n" |
| 1884 |
"\\&\n" |
| 1885 |
" for (;;) {\n" |
| 1886 |
" char host[NI_MAXHOST], service[NI_MAXSERV];\n" |
| 1887 |
"\\&\n" |
| 1888 |
" peer_addrlen = sizeof(peer_addr);\n" |
| 1889 |
" nread = recvfrom(sfd, buf, BUF_SIZE, 0,\n" |
| 1890 |
" (struct sockaddr *) &peer_addr, &peer_addrlen);\n" |
| 1891 |
" if (nread == -1)\n" |
| 1892 |
" continue; /* Ignore failed request */\n" |
| 1893 |
"\\&\n" |
| 1894 |
" s = getnameinfo((struct sockaddr *) &peer_addr,\n" |
| 1895 |
" peer_addrlen, host, NI_MAXHOST,\n" |
| 1896 |
" service, NI_MAXSERV, NI_NUMERICSERV);\n" |
| 1897 |
" if (s == 0)\n" |
| 1898 |
" printf(\"Received %zd bytes from %s:%s\\[rs]n\",\n" |
| 1899 |
" nread, host, service);\n" |
| 1900 |
" else\n" |
| 1901 |
" fprintf(stderr, \"getnameinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1902 |
"\\&\n" |
| 1903 |
" if (sendto(sfd, buf, nread, 0, (struct sockaddr *) &peer_addr,\n" |
| 1904 |
" peer_addrlen) != nread)\n" |
| 1905 |
" {\n" |
| 1906 |
" fprintf(stderr, \"Error sending response\\[rs]n\");\n" |
| 1907 |
" }\n" |
| 1908 |
" }\n" |
| 1909 |
"}\n" |
| 1910 |
msgstr "" |
| 1911 |
"#include E<lt>netdb.hE<gt>\n" |
| 1912 |
"#include E<lt>stdio.hE<gt>\n" |
| 1913 |
"#include E<lt>stdlib.hE<gt>\n" |
| 1914 |
"#include E<lt>string.hE<gt>\n" |
| 1915 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 1916 |
"#include E<lt>sys/types.hE<gt>\n" |
| 1917 |
"#include E<lt>unistd.hE<gt>\n" |
| 1918 |
"\\&\n" |
| 1919 |
"#define BUF_SIZE 500\n" |
| 1920 |
"\\&\n" |
| 1921 |
"int\n" |
| 1922 |
"main(int argc, char *argv[])\n" |
| 1923 |
"{\n" |
| 1924 |
" int sfd, s;\n" |
| 1925 |
" char buf[BUF_SIZE];\n" |
| 1926 |
" ssize_t nread;\n" |
| 1927 |
" socklen_t peer_addrlen;\n" |
| 1928 |
" struct addrinfo hints;\n" |
| 1929 |
" struct addrinfo *result, *rp;\n" |
| 1930 |
" struct sockaddr_storage peer_addr;\n" |
| 1931 |
"\\&\n" |
| 1932 |
" if (argc != 2) {\n" |
| 1933 |
" fprintf(stderr, \"Utilisation : %s port\\[rs]n\", argv[0]);\n" |
| 1934 |
" exit(EXIT_FAILURE);\n" |
| 1935 |
" }\n" |
| 1936 |
"\\&\n" |
| 1937 |
" memset(&hints, 0, sizeof(hints));\n" |
| 1938 |
" hints.ai_family = AF_UNSPEC; /* IPv4 ou IPv6 permis */\n" |
| 1939 |
" hints.ai_socktype = SOCK_DGRAM; /* Socket du datagramme */\n" |
| 1940 |
" hints.ai_flags = AI_PASSIVE; /* Pour une adresse IP joker */\n" |
| 1941 |
" hints.ai_protocol = 0; /* Tout protocole */\n" |
| 1942 |
" hints.ai_canonname = NULL;\n" |
| 1943 |
" hints.ai_addr = NULL;\n" |
| 1944 |
" hints.ai_next = NULL;\n" |
| 1945 |
"\\&\n" |
| 1946 |
" s = getaddrinfo(NULL, argv[1], &hints, &result);\n" |
| 1947 |
" if (s != 0) {\n" |
| 1948 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 1949 |
" exit(EXIT_FAILURE);\n" |
| 1950 |
" }\n" |
| 1951 |
"\\&\n" |
| 1952 |
" /* getaddrinfo() renvoie une liste de structures d'adresse.\n" |
| 1953 |
" Essayer cheque adresse jusqu'à un bind(2) réussi.\n" |
| 1954 |
" Si socket(2) (ou bind(2)) échoue, on (clôt le socket\n" |
| 1955 |
" et) essaie l'adresse suivante. */\n" |
| 1956 |
"\\&\n" |
| 1957 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 1958 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 1959 |
" rp-E<gt>ai_protocol);\n" |
| 1960 |
" if (sfd == -1)\n" |
| 1961 |
" continue;\n" |
| 1962 |
"\\&\n" |
| 1963 |
" if (bind(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) == 0)\n" |
| 1964 |
" break; /* Succès */\n" |
| 1965 |
"\\&\n" |
| 1966 |
" close(sfd);\n" |
| 1967 |
" }\n" |
| 1968 |
"\\&\n" |
| 1969 |
" freeaddrinfo(result); /* Plus nécessaire */\n" |
| 1970 |
"\\&\n" |
| 1971 |
" if (rp == NULL) { /* Toutes les adresses ont échoué */\n" |
| 1972 |
" fprintf(stderr, \"Pas de lien créé\\[rs]n\");\n" |
| 1973 |
" exit(EXIT_FAILURE);\n" |
| 1974 |
" }\n" |
| 1975 |
"\\&\n" |
| 1976 |
" /* Lire les datagrammes et les renvoyer à l'envoyeur. */\n" |
| 1977 |
"\\&\n" |
| 1978 |
" for (;;) {\n" |
| 1979 |
" char host[NI_MAXHOST], service[NI_MAXSERV];\n" |
| 1980 |
"\\&\n" |
| 1981 |
" peer_addrlen = sizeof(peer_addr);\n" |
| 1982 |
" nread = recvfrom(sfd, buf, BUF_SIZE, 0,\n" |
| 1983 |
" (struct sockaddr *) &peer_addr, &peer_addrlen);\n" |
| 1984 |
" if (nread == -1)\n" |
| 1985 |
" continue; /* Ignorer la requête en échec */\n" |
| 1986 |
"\\&\n" |
| 1987 |
" s = getnameinfo((struct sockaddr *) &peer_addr,\n" |
| 1988 |
" peer_addrlen, host, NI_MAXHOST,\n" |
| 1989 |
" service, NI_MAXSERV, NI_NUMERICSERV);\n" |
| 1990 |
" if (s == 0)\n" |
| 1991 |
" printf(\"%zd octets reçus de %s:%s\\[rs]n\",\n" |
| 1992 |
" nread, host, service);\n" |
| 1993 |
" else\n" |
| 1994 |
" fprintf(stderr, \"getnameinfo : %s\\[rs]n\", gai_strerror(s));\n" |
| 1995 |
"\\&\n" |
| 1996 |
" if (sendto(sfd, buf, nread, 0, (struct sockaddr *) &peer_addr,\n" |
| 1997 |
" peer_addrlen) != nread)\n" |
| 1998 |
" {\n" |
| 1999 |
" fprintf(stderr, \"Erreur d'envoi de réponse\\[rs]n\");\n" |
| 2000 |
" }\n" |
| 2001 |
" }\n" |
| 2002 |
"}\n" |
| 2003 |
|
| 2004 |
#. type: Plain text |
| 2005 |
#: debian-trixie |
| 2006 |
#, no-wrap |
| 2007 |
msgid "" |
| 2008 |
"#include E<lt>netdb.hE<gt>\n" |
| 2009 |
"#include E<lt>stdio.hE<gt>\n" |
| 2010 |
"#include E<lt>stdlib.hE<gt>\n" |
| 2011 |
"#include E<lt>string.hE<gt>\n" |
| 2012 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 2013 |
"#include E<lt>sys/types.hE<gt>\n" |
| 2014 |
"#include E<lt>unistd.hE<gt>\n" |
| 2015 |
"\\&\n" |
| 2016 |
"#define BUF_SIZE 500\n" |
| 2017 |
"\\&\n" |
| 2018 |
"int\n" |
| 2019 |
"main(int argc, char *argv[])\n" |
| 2020 |
"{\n" |
| 2021 |
" int sfd, s;\n" |
| 2022 |
" char buf[BUF_SIZE];\n" |
| 2023 |
" size_t len;\n" |
| 2024 |
" ssize_t nread;\n" |
| 2025 |
" struct addrinfo hints;\n" |
| 2026 |
" struct addrinfo *result, *rp;\n" |
| 2027 |
"\\&\n" |
| 2028 |
" if (argc E<lt> 3) {\n" |
| 2029 |
" fprintf(stderr, \"Usage: %s host port msg...\\[rs]n\", argv[0]);\n" |
| 2030 |
" exit(EXIT_FAILURE);\n" |
| 2031 |
" }\n" |
| 2032 |
"\\&\n" |
| 2033 |
" /* Obtain address(es) matching host/port. */\n" |
| 2034 |
"\\&\n" |
| 2035 |
" memset(&hints, 0, sizeof(hints));\n" |
| 2036 |
" hints.ai_family = AF_UNSPEC; /* Allow IPv4 or IPv6 */\n" |
| 2037 |
" hints.ai_socktype = SOCK_DGRAM; /* Datagram socket */\n" |
| 2038 |
" hints.ai_flags = 0;\n" |
| 2039 |
" hints.ai_protocol = 0; /* Any protocol */\n" |
| 2040 |
"\\&\n" |
| 2041 |
" s = getaddrinfo(argv[1], argv[2], &hints, &result);\n" |
| 2042 |
" if (s != 0) {\n" |
| 2043 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 2044 |
" exit(EXIT_FAILURE);\n" |
| 2045 |
" }\n" |
| 2046 |
"\\&\n" |
| 2047 |
" /* getaddrinfo() returns a list of address structures.\n" |
| 2048 |
" Try each address until we successfully connect(2).\n" |
| 2049 |
" If socket(2) (or connect(2)) fails, we (close the socket\n" |
| 2050 |
" and) try the next address. */\n" |
| 2051 |
"\\&\n" |
| 2052 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 2053 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 2054 |
" rp-E<gt>ai_protocol);\n" |
| 2055 |
" if (sfd == -1)\n" |
| 2056 |
" continue;\n" |
| 2057 |
"\\&\n" |
| 2058 |
" if (connect(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) != -1)\n" |
| 2059 |
" break; /* Success */\n" |
| 2060 |
"\\&\n" |
| 2061 |
" close(sfd);\n" |
| 2062 |
" }\n" |
| 2063 |
"\\&\n" |
| 2064 |
" freeaddrinfo(result); /* No longer needed */\n" |
| 2065 |
"\\&\n" |
| 2066 |
" if (rp == NULL) { /* No address succeeded */\n" |
| 2067 |
" fprintf(stderr, \"Could not connect\\[rs]n\");\n" |
| 2068 |
" exit(EXIT_FAILURE);\n" |
| 2069 |
" }\n" |
| 2070 |
"\\&\n" |
| 2071 |
" /* Send remaining command-line arguments as separate\n" |
| 2072 |
" datagrams, and read responses from server. */\n" |
| 2073 |
"\\&\n" |
| 2074 |
" for (size_t j = 3; j E<lt> argc; j++) {\n" |
| 2075 |
" len = strlen(argv[j]) + 1;\n" |
| 2076 |
" /* +1 for terminating null byte */\n" |
| 2077 |
"\\&\n" |
| 2078 |
" if (len E<gt> BUF_SIZE) {\n" |
| 2079 |
" fprintf(stderr,\n" |
| 2080 |
" \"Ignoring long message in argument %zu\\[rs]n\", j);\n" |
| 2081 |
" continue;\n" |
| 2082 |
" }\n" |
| 2083 |
"\\&\n" |
| 2084 |
" if (write(sfd, argv[j], len) != len) {\n" |
| 2085 |
" fprintf(stderr, \"partial/failed write\\[rs]n\");\n" |
| 2086 |
" exit(EXIT_FAILURE);\n" |
| 2087 |
" }\n" |
| 2088 |
"\\&\n" |
| 2089 |
" nread = read(sfd, buf, BUF_SIZE);\n" |
| 2090 |
" if (nread == -1) {\n" |
| 2091 |
" perror(\"read\");\n" |
| 2092 |
" exit(EXIT_FAILURE);\n" |
| 2093 |
" }\n" |
| 2094 |
"\\&\n" |
| 2095 |
" printf(\"Received %zd bytes: %s\\[rs]n\", nread, buf);\n" |
| 2096 |
" }\n" |
| 2097 |
"\\&\n" |
| 2098 |
" exit(EXIT_SUCCESS);\n" |
| 2099 |
"}\n" |
| 2100 |
msgstr "" |
| 2101 |
"#include E<lt>netdb.hE<gt>\n" |
| 2102 |
"#include E<lt>stdio.hE<gt>\n" |
| 2103 |
"#include E<lt>stdlib.hE<gt>\n" |
| 2104 |
"#include E<lt>string.hE<gt>\n" |
| 2105 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 2106 |
"#include E<lt>sys/types.hE<gt>\n" |
| 2107 |
"#include E<lt>unistd.hE<gt>\n" |
| 2108 |
"\\&\n" |
| 2109 |
"#define BUF_SIZE 500\n" |
| 2110 |
"\\&\n" |
| 2111 |
"int\n" |
| 2112 |
"main(int argc, char *argv[])\n" |
| 2113 |
"{\n" |
| 2114 |
" int sfd, s;\n" |
| 2115 |
" char buf[BUF_SIZE];\n" |
| 2116 |
" size_t len;\n" |
| 2117 |
" ssize_t nread;\n" |
| 2118 |
" struct addrinfo hints;\n" |
| 2119 |
" struct addrinfo *result, *rp;\n" |
| 2120 |
"\\&\n" |
| 2121 |
" if (argc E<lt> 3) {\n" |
| 2122 |
" fprintf(stderr, \"Utilisation : %s host port msg...\\[rs]n\", argv[0]);\n" |
| 2123 |
" exit(EXIT_FAILURE);\n" |
| 2124 |
" }\n" |
| 2125 |
"\\&\n" |
| 2126 |
" /* Obtenir les adresses correspondantes hôte/port. */\n" |
| 2127 |
"\\&\n" |
| 2128 |
" memset(&hints, 0, sizeof(hints));\n" |
| 2129 |
" hints.ai_family = AF_UNSPEC; /* IPv4 ou IPv6 permis */\n" |
| 2130 |
" hints.ai_socktype = SOCK_DGRAM; /* Socket du datagramme */\n" |
| 2131 |
" hints.ai_flags = 0;\n" |
| 2132 |
" hints.ai_protocol = 0; /* Tout protocole */\n" |
| 2133 |
"\\&\n" |
| 2134 |
" s = getaddrinfo(argv[1], argv[2], &hints, &result);\n" |
| 2135 |
" if (s != 0) {\n" |
| 2136 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 2137 |
" exit(EXIT_FAILURE);\n" |
| 2138 |
" }\n" |
| 2139 |
"\\&\n" |
| 2140 |
" /* getaddrinfo() renvoie une liste de structures d'adresse.\n" |
| 2141 |
" Essayer chaque adresse jusqu'à un bind(2) réussi.\n" |
| 2142 |
" Si socket(2) (ou bind(2)) échoue, on (clôt le socket\n" |
| 2143 |
" et) essaie l'adresse suivante. */\n" |
| 2144 |
"\\&\n" |
| 2145 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 2146 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 2147 |
" rp-E<gt>ai_protocol);\n" |
| 2148 |
" if (sfd == -1)\n" |
| 2149 |
" continue;\n" |
| 2150 |
"\\&\n" |
| 2151 |
" if (connect(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) != -1)\n" |
| 2152 |
" break; /* Succès */\n" |
| 2153 |
"\\&\n" |
| 2154 |
" close(sfd);\n" |
| 2155 |
" }\n" |
| 2156 |
"\\&\n" |
| 2157 |
" freeaddrinfo(result); /* Plus nécessaire */\n" |
| 2158 |
"\\&\n" |
| 2159 |
" if (rp == NULL) { /* Toutes les adresses ont échoué */\n" |
| 2160 |
" fprintf(stderr, \"Connexion impossible\\[rs]n\");\n" |
| 2161 |
" exit(EXIT_FAILURE);\n" |
| 2162 |
" }\n" |
| 2163 |
"\\&\n" |
| 2164 |
" /* Envoyer les arguments en ligne de commande comme des datagrammes\n" |
| 2165 |
" séparés et lire les réponses du serveur. */\n" |
| 2166 |
"\\&\n" |
| 2167 |
" for (size_t j = 3; j E<lt> argc; j++) {\n" |
| 2168 |
" len = strlen(argv[j]) + 1;\n" |
| 2169 |
" /* +1 pour l'octet NULL de terminaison */\n" |
| 2170 |
"\\&\n" |
| 2171 |
" if (len E<gt> BUF_SIZE) {\n" |
| 2172 |
" fprintf(stderr,\n" |
| 2173 |
" \"Ignorer le message long dans l'argument %zu\\[rs]n\", j);\n" |
| 2174 |
" continue;\n" |
| 2175 |
" }\n" |
| 2176 |
"\\&\n" |
| 2177 |
" if (write(sfd, argv[j], len) != len) {\n" |
| 2178 |
" fprintf(stderr, \"écriture partielle/échec\\[rs]n\");\n" |
| 2179 |
" exit(EXIT_FAILURE);\n" |
| 2180 |
" }\n" |
| 2181 |
"\\&\n" |
| 2182 |
" nread = read(sfd, buf, BUF_SIZE);\n" |
| 2183 |
" if (nread == -1) {\n" |
| 2184 |
" perror(\"read\");\n" |
| 2185 |
" exit(EXIT_FAILURE);\n" |
| 2186 |
" }\n" |
| 2187 |
"\\&\n" |
| 2188 |
" printf(\"%zd octets reçus de : %s\\[rs]n\", nread, buf);\n" |
| 2189 |
" }\n" |
| 2190 |
"\\&\n" |
| 2191 |
" exit(EXIT_SUCCESS);\n" |
| 2192 |
"}\n" |
| 2193 |
|
| 2194 |
#. type: TH |
| 2195 |
#: fedora-44 fedora-rawhide |
| 2196 |
#, no-wrap |
| 2197 |
msgid "2024-11-17" |
| 2198 |
msgstr "17 novembre 2024" |
| 2199 |
|
| 2200 |
#. type: TH |
| 2201 |
#: fedora-44 fedora-rawhide |
| 2202 |
#, no-wrap |
| 2203 |
msgid "Linux man-pages 6.13" |
| 2204 |
msgstr "Pages du manuel de Linux 6.13" |
| 2205 |
|
| 2206 |
#. type: Plain text |
| 2207 |
#: fedora-44 fedora-rawhide |
| 2208 |
#, no-wrap |
| 2209 |
msgid "" |
| 2210 |
"#include E<lt>netdb.hE<gt>\n" |
| 2211 |
"#include E<lt>stdio.hE<gt>\n" |
| 2212 |
"#include E<lt>stdlib.hE<gt>\n" |
| 2213 |
"#include E<lt>string.hE<gt>\n" |
| 2214 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 2215 |
"#include E<lt>sys/types.hE<gt>\n" |
| 2216 |
"#include E<lt>unistd.hE<gt>\n" |
| 2217 |
"\\&\n" |
| 2218 |
"#define BUF_SIZE 500\n" |
| 2219 |
"\\&\n" |
| 2220 |
"int\n" |
| 2221 |
"main(int argc, char *argv[])\n" |
| 2222 |
"{\n" |
| 2223 |
" int sfd, s;\n" |
| 2224 |
" char buf[BUF_SIZE];\n" |
| 2225 |
" size_t size;\n" |
| 2226 |
" ssize_t nread;\n" |
| 2227 |
" struct addrinfo hints;\n" |
| 2228 |
" struct addrinfo *result, *rp;\n" |
| 2229 |
"\\&\n" |
| 2230 |
" if (argc E<lt> 3) {\n" |
| 2231 |
" fprintf(stderr, \"Usage: %s host port msg...\\[rs]n\", argv[0]);\n" |
| 2232 |
" exit(EXIT_FAILURE);\n" |
| 2233 |
" }\n" |
| 2234 |
"\\&\n" |
| 2235 |
" /* Obtain address(es) matching host/port. */\n" |
| 2236 |
"\\&\n" |
| 2237 |
" memset(&hints, 0, sizeof(hints));\n" |
| 2238 |
" hints.ai_family = AF_UNSPEC; /* Allow IPv4 or IPv6 */\n" |
| 2239 |
" hints.ai_socktype = SOCK_DGRAM; /* Datagram socket */\n" |
| 2240 |
" hints.ai_flags = 0;\n" |
| 2241 |
" hints.ai_protocol = 0; /* Any protocol */\n" |
| 2242 |
"\\&\n" |
| 2243 |
" s = getaddrinfo(argv[1], argv[2], &hints, &result);\n" |
| 2244 |
" if (s != 0) {\n" |
| 2245 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 2246 |
" exit(EXIT_FAILURE);\n" |
| 2247 |
" }\n" |
| 2248 |
"\\&\n" |
| 2249 |
" /* getaddrinfo() returns a list of address structures.\n" |
| 2250 |
" Try each address until we successfully connect(2).\n" |
| 2251 |
" If socket(2) (or connect(2)) fails, we (close the socket\n" |
| 2252 |
" and) try the next address. */\n" |
| 2253 |
"\\&\n" |
| 2254 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 2255 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 2256 |
" rp-E<gt>ai_protocol);\n" |
| 2257 |
" if (sfd == -1)\n" |
| 2258 |
" continue;\n" |
| 2259 |
"\\&\n" |
| 2260 |
" if (connect(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) != -1)\n" |
| 2261 |
" break; /* Success */\n" |
| 2262 |
"\\&\n" |
| 2263 |
" close(sfd);\n" |
| 2264 |
" }\n" |
| 2265 |
"\\&\n" |
| 2266 |
" freeaddrinfo(result); /* No longer needed */\n" |
| 2267 |
"\\&\n" |
| 2268 |
" if (rp == NULL) { /* No address succeeded */\n" |
| 2269 |
" fprintf(stderr, \"Could not connect\\[rs]n\");\n" |
| 2270 |
" exit(EXIT_FAILURE);\n" |
| 2271 |
" }\n" |
| 2272 |
"\\&\n" |
| 2273 |
" /* Send remaining command-line arguments as separate\n" |
| 2274 |
" datagrams, and read responses from server. */\n" |
| 2275 |
"\\&\n" |
| 2276 |
" for (size_t j = 3; j E<lt> argc; j++) {\n" |
| 2277 |
" size = strlen(argv[j]) + 1;\n" |
| 2278 |
" /* +1 for terminating null byte */\n" |
| 2279 |
"\\&\n" |
| 2280 |
" if (size E<gt> BUF_SIZE) {\n" |
| 2281 |
" fprintf(stderr,\n" |
| 2282 |
" \"Ignoring long message in argument %zu\\[rs]n\", j);\n" |
| 2283 |
" continue;\n" |
| 2284 |
" }\n" |
| 2285 |
"\\&\n" |
| 2286 |
" if (write(sfd, argv[j], size) != size) {\n" |
| 2287 |
" fprintf(stderr, \"partial/failed write\\[rs]n\");\n" |
| 2288 |
" exit(EXIT_FAILURE);\n" |
| 2289 |
" }\n" |
| 2290 |
"\\&\n" |
| 2291 |
" nread = read(sfd, buf, BUF_SIZE);\n" |
| 2292 |
" if (nread == -1) {\n" |
| 2293 |
" perror(\"read\");\n" |
| 2294 |
" exit(EXIT_FAILURE);\n" |
| 2295 |
" }\n" |
| 2296 |
"\\&\n" |
| 2297 |
" printf(\"Received %zd bytes: %s\\[rs]n\", nread, buf);\n" |
| 2298 |
" }\n" |
| 2299 |
"\\&\n" |
| 2300 |
" exit(EXIT_SUCCESS);\n" |
| 2301 |
"}\n" |
| 2302 |
msgstr "" |
| 2303 |
"#include E<lt>netdb.hE<gt>\n" |
| 2304 |
"#include E<lt>stdio.hE<gt>\n" |
| 2305 |
"#include E<lt>stdlib.hE<gt>\n" |
| 2306 |
"#include E<lt>string.hE<gt>\n" |
| 2307 |
"#include E<lt>sys/socket.hE<gt>\n" |
| 2308 |
"#include E<lt>sys/types.hE<gt>\n" |
| 2309 |
"#include E<lt>unistd.hE<gt>\n" |
| 2310 |
"\\&\n" |
| 2311 |
"#define BUF_SIZE 500\n" |
| 2312 |
"\\&\n" |
| 2313 |
"int\n" |
| 2314 |
"main(int argc, char *argv[])\n" |
| 2315 |
"{\n" |
| 2316 |
" int sfd, s;\n" |
| 2317 |
" char buf[BUF_SIZE];\n" |
| 2318 |
" size_t size;\n" |
| 2319 |
" ssize_t nread;\n" |
| 2320 |
" struct addrinfo hints;\n" |
| 2321 |
" struct addrinfo *result, *rp;\n" |
| 2322 |
"\\&\n" |
| 2323 |
" if (argc E<lt> 3) {\n" |
| 2324 |
" fprintf(stderr, \"Utilisation : %s host port msg...\\[rs]n\", argv[0]);\n" |
| 2325 |
" exit(EXIT_FAILURE);\n" |
| 2326 |
" }\n" |
| 2327 |
"\\&\n" |
| 2328 |
" /* Obtenir les adresses correspondantes hôte/port. */\n" |
| 2329 |
"\\&\n" |
| 2330 |
" memset(&hints, 0, sizeof(hints));\n" |
| 2331 |
" hints.ai_family = AF_UNSPEC; /* IPv4 ou IPv6 permis */\n" |
| 2332 |
" hints.ai_socktype = SOCK_DGRAM; /* Socket du datagramme */\n" |
| 2333 |
" hints.ai_flags = 0;\n" |
| 2334 |
" hints.ai_protocol = 0; /* Tout protocole */\n" |
| 2335 |
"\\&\n" |
| 2336 |
" s = getaddrinfo(argv[1], argv[2], &hints, &result);\n" |
| 2337 |
" if (s != 0) {\n" |
| 2338 |
" fprintf(stderr, \"getaddrinfo: %s\\[rs]n\", gai_strerror(s));\n" |
| 2339 |
" exit(EXIT_FAILURE);\n" |
| 2340 |
" }\n" |
| 2341 |
"\\&\n" |
| 2342 |
" /* getaddrinfo() renvoie une liste de structures d'adresse.\n" |
| 2343 |
" Essayer chaque adresse jusqu'à un bind(2) réussi.\n" |
| 2344 |
" Si socket(2) (ou bind(2)) échoue, on (clôt le socket\n" |
| 2345 |
" et) essaie l'adresse suivante. */\n" |
| 2346 |
"\\&\n" |
| 2347 |
" for (rp = result; rp != NULL; rp = rp-E<gt>ai_next) {\n" |
| 2348 |
" sfd = socket(rp-E<gt>ai_family, rp-E<gt>ai_socktype,\n" |
| 2349 |
" rp-E<gt>ai_protocol);\n" |
| 2350 |
" if (sfd == -1)\n" |
| 2351 |
" continue;\n" |
| 2352 |
"\\&\n" |
| 2353 |
" if (connect(sfd, rp-E<gt>ai_addr, rp-E<gt>ai_addrlen) != -1)\n" |
| 2354 |
" break; /* Succès */\n" |
| 2355 |
"\\&\n" |
| 2356 |
" close(sfd);\n" |
| 2357 |
" }\n" |
| 2358 |
"\\&\n" |
| 2359 |
" freeaddrinfo(result); /* Plus nécessaire */\n" |
| 2360 |
"\\&\n" |
| 2361 |
" if (rp == NULL) { /* Toutes les adresses ont échoué */\n" |
| 2362 |
" fprintf(stderr, \"Connexion impossible\\[rs]n\");\n" |
| 2363 |
" exit(EXIT_FAILURE);\n" |
| 2364 |
" }\n" |
| 2365 |
"\\&\n" |
| 2366 |
" /* Envoyer les arguments en ligne de commande comme des datagrammes\n" |
| 2367 |
" séparés et lire les réponses du serveur. */\n" |
| 2368 |
"\\&\n" |
| 2369 |
" for (size_t j = 3; j E<lt> argc; j++) {\n" |
| 2370 |
" size = strlen(argv[j]) + 1;\n" |
| 2371 |
" /* +1 pour l'octet NULL de terminaison */\n" |
| 2372 |
"\\&\n" |
| 2373 |
" if (size E<gt> BUF_SIZE) {\n" |
| 2374 |
" fprintf(stderr,\n" |
| 2375 |
" \"Ignorer le message long dans l'argument %zu\\[rs]n\", j);\n" |
| 2376 |
" continue;\n" |
| 2377 |
" }\n" |
| 2378 |
"\\&\n" |
| 2379 |
" if (write(sfd, argv[j], size) != size) {\n" |
| 2380 |
" fprintf(stderr, \"écriture partielle/échec\\[rs]n\");\n" |
| 2381 |
" exit(EXIT_FAILURE);\n" |
| 2382 |
" }\n" |
| 2383 |
"\\&\n" |
| 2384 |
" nread = read(sfd, buf, BUF_SIZE);\n" |
| 2385 |
" if (nread == -1) {\n" |
| 2386 |
" perror(\"read\");\n" |
| 2387 |
" exit(EXIT_FAILURE);\n" |
| 2388 |
" }\n" |
| 2389 |
"\\&\n" |
| 2390 |
" printf(\"%zd octets reçus de : %s\\[rs]n\", nread, buf);\n" |
| 2391 |
" }\n" |
| 2392 |
"\\&\n" |
| 2393 |
" exit(EXIT_SUCCESS);\n" |
| 2394 |
"}\n" |
| 2395 |
|
| 2396 |
#. type: TH |
| 2397 |
#: mageia-cauldron |
| 2398 |
#, no-wrap |
| 2399 |
msgid "Linux man-pages 6.17" |
| 2400 |
msgstr "Pages du manuel de Linux 6.17" |
| 2401 |
|
| 2402 |
#. type: TH |
| 2403 |
#: opensuse-leap-16-1 opensuse-tumbleweed |
| 2404 |
#, no-wrap |
| 2405 |
msgid "Linux man-pages (unreleased)" |
| 2406 |
msgstr "Pages du manuel de Linux (non publiées)" |
| 2407 |
|
| 2408 |
#. .BR getipnodebyaddr (3), |
| 2409 |
#. .BR getipnodebyname (3), |
| 2410 |
#. type: Plain text |
| 2411 |
#: opensuse-leap-16-1 opensuse-tumbleweed |
| 2412 |
msgid "" |
| 2413 |
"B<getaddrinfo_a>(3), B<gethostbyname>(3), B<getnameinfo>(3), B<gai.conf>(5), " |
| 2414 |
"B<inet>(3), B<gai.conf>(5), B<hostname>(7), B<ip>(7)" |
| 2415 |
msgstr "" |
| 2416 |
"B<getaddrinfo_a>(3), B<gethostbyname>(3), B<getnameinfo>(3), B<gai.conf>(5), " |
| 2417 |
"B<inet>(3), B<gai.conf>(5), B<hostname>(7), B<ip>(7)" |