Debian Codegraph @

po/ro/man3/getifaddrs.3.po

raw
1 # Romanian translation of manpages
2 # This file is distributed under the same license as the manpages-l10n package.
3 # Copyright © of this file:
4 # Remus-Gabriel Chelu <[email protected]>, 2025.
5 msgid ""
6 msgstr ""
7 "Project-Id-Version: manpages-l10n 4.25.1\n"
8 "POT-Creation-Date: 2026-05-01 04:28+0200\n"
9 "PO-Revision-Date: 2025-11-05 12:56+0100\n"
10 "Last-Translator: Remus-Gabriel Chelu <[email protected]>\n"
11 "Language-Team: Romanian <[email protected]>\n"
12 "Language: ro\n"
13 "MIME-Version: 1.0\n"
14 "Content-Type: text/plain; charset=UTF-8\n"
15 "Content-Transfer-Encoding: 8bit\n"
16 "Plural-Forms: nplurals=3; plural=n==1 ? 0 : (n==0 || (n%100 > 0 && n%100 < "
17 "20)) ? 1 : 2;\n"
18 "X-Generator: Poedit 3.6\n"
19
20 #. type: TH
21 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
22 #: mageia-cauldron
23 #, no-wrap
24 msgid "getifaddrs"
25 msgstr "getifaddrs"
26
27 #. type: TH
28 #: archlinux debian-unstable mageia-cauldron
29 #, no-wrap
30 msgid "2026-02-08"
31 msgstr "8 februarie 2026"
32
33 #. type: TH
34 #: archlinux debian-unstable
35 #, no-wrap
36 msgid "Linux man-pages 6.18"
37 msgstr "Pagini de manual de Linux 6.18"
38
39 #. type: SH
40 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
41 #: mageia-cauldron
42 #, no-wrap
43 msgid "NAME"
44 msgstr "NUME"
45
46 #. type: Plain text
47 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
48 #: mageia-cauldron
49 msgid "getifaddrs, freeifaddrs - get interface addresses"
50 msgstr "getifaddrs, freeifaddrs - obține adrese de interfațe"
51
52 #. type: SH
53 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
54 #: mageia-cauldron
55 #, no-wrap
56 msgid "LIBRARY"
57 msgstr "BIBLIOTECA"
58
59 #. type: Plain text
60 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
61 msgid "Standard C library (I<libc>,\\ I<-lc>)"
62 msgstr "Biblioteca C standard (I<libc>, I<-lc>)"
63
64 #. type: SH
65 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
66 #: mageia-cauldron
67 #, no-wrap
68 msgid "SYNOPSIS"
69 msgstr "SINOPSIS"
70
71 #. type: Plain text
72 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
73 #: mageia-cauldron
74 #, no-wrap
75 msgid ""
76 "B<#include E<lt>sys/types.hE<gt>>\n"
77 "B<#include E<lt>ifaddrs.hE<gt>>\n"
78 msgstr ""
79 "B<#include E<lt>sys/types.hE<gt>>\n"
80 "B<#include E<lt>ifaddrs.hE<gt>>\n"
81
82 #. type: Plain text
83 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
84 #: mageia-cauldron
85 #, no-wrap
86 msgid ""
87 "B<int getifaddrs(struct ifaddrs **>I<ifap>B<);>\n"
88 "B<void freeifaddrs(struct ifaddrs *>I<ifa>B<);>\n"
89 msgstr ""
90 "B<int getifaddrs(struct ifaddrs **>I<ifap>B<);>\n"
91 "B<void freeifaddrs(struct ifaddrs *>I<ifa>B<);>\n"
92
93 #. type: SH
94 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
95 #: mageia-cauldron
96 #, no-wrap
97 msgid "DESCRIPTION"
98 msgstr "DESCRIERE"
99
100 #. type: Plain text
101 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
102 #: mageia-cauldron
103 msgid ""
104 "The B<getifaddrs>() function creates a linked list of structures describing "
105 "the network interfaces of the local system, and stores the address of the "
106 "first item of the list in I<*ifap>. The list consists of I<ifaddrs> "
107 "structures, defined as follows:"
108 msgstr ""
109 "Funcția B<getifaddrs>() creează o listă legată de structuri care descriu "
110 "interfețele de rețea ale sistemului local și stochează adresa primului "
111 "element al listei în I<*ifap>. Lista este formată din structuri I<ifaddrs>, "
112 "definite după cum urmează:"
113
114 #. type: Plain text
115 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
116 #: mageia-cauldron
117 #, no-wrap
118 msgid ""
119 "struct ifaddrs {\n"
120 " struct ifaddrs *ifa_next; /* Next item in list */\n"
121 " char *ifa_name; /* Name of interface */\n"
122 " unsigned int ifa_flags; /* Flags from SIOCGIFFLAGS */\n"
123 " struct sockaddr *ifa_addr; /* Address of interface */\n"
124 " struct sockaddr *ifa_netmask; /* Netmask of interface */\n"
125 " union {\n"
126 " struct sockaddr *ifu_broadaddr;\n"
127 " /* Broadcast address of interface */\n"
128 " struct sockaddr *ifu_dstaddr;\n"
129 " /* Point-to-point destination address */\n"
130 " } ifa_ifu;\n"
131 "#define ifa_broadaddr ifa_ifu.ifu_broadaddr\n"
132 "#define ifa_dstaddr ifa_ifu.ifu_dstaddr\n"
133 " void *ifa_data; /* Address-specific data */\n"
134 "};\n"
135 msgstr ""
136 "struct ifaddrs {\n"
137 " struct ifaddrs *ifa_next; /* Următorul element din listă */\n"
138 " char *ifa_name; /* Numele interfeței */\n"
139 " unsigned int ifa_flags; /* Fanioane de la SIOCGIFFLAGS */\n"
140 " struct sockaddr *ifa_addr; /* Adresa interfeței */\n"
141 " struct sockaddr *ifa_netmask; /* Masca de rețea a interfeței */\n"
142 " union {\n"
143 " struct sockaddr *ifu_broadaddr;\n"
144 " /* Adresa de difuzare a interfeței */\n"
145 " struct sockaddr *ifu_dstaddr;\n"
146 " /* Adresa de destinație punct-la-punct */\n"
147 " } ifa_ifu;\n"
148 "#define ifa_broadaddr ifa_ifu.ifu_broadaddr\n"
149 "#define ifa_dstaddr ifa_ifu.ifu_dstaddr\n"
150 " void *ifa_data; /* Date specifice adresei */\n"
151 "};\n"
152
153 #. type: Plain text
154 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
155 #: mageia-cauldron
156 msgid ""
157 "The I<ifa_next> field contains a pointer to the next structure on the list, "
158 "or NULL if this is the last item of the list."
159 msgstr ""
160 "Câmpul I<ifa_next> conține un indicator către următoarea structură din listă "
161 "sau NULL dacă acesta este ultimul element din listă."
162
163 #. The constant
164 #. .B IF NAMESIZE
165 #. indicates the maximum length of this field.
166 #. type: Plain text
167 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
168 #: mageia-cauldron
169 msgid "The I<ifa_name> points to the null-terminated interface name."
170 msgstr "I<ifa_name> indică numele interfeței terminat prin nul."
171
172 #. type: Plain text
173 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
174 #: mageia-cauldron
175 msgid ""
176 "The I<ifa_flags> field contains the interface flags, as returned by the "
177 "B<SIOCGIFFLAGS> B<ioctl>(2) operation (see B<netdevice>(7) for a list of "
178 "these flags)."
179 msgstr ""
180 "Câmpul I<ifa_flags> conține fanioanele interfeței, astfel cum sunt returnate "
181 "de operația B<SIOCGIFFLAGS> B<ioctl>(2) (a se vedea B<netdevice>(7) pentru o "
182 "listă a acestor fanioane)."
183
184 #. type: Plain text
185 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
186 #: mageia-cauldron
187 msgid ""
188 "The I<ifa_addr> field points to a structure containing the interface "
189 "address. (The I<sa_family> subfield should be consulted to determine the "
190 "format of the address structure.) This field may contain a null pointer."
191 msgstr ""
192 "Câmpul I<ifa_addr> trimite la o structură care conține adresa interfeței; "
193 "(subcâmpul I<sa_family> trebuie consultat pentru a determina formatul "
194 "structurii de adrese). Acest câmp poate conține un indicator nul."
195
196 #. type: Plain text
197 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
198 #: mageia-cauldron
199 msgid ""
200 "The I<ifa_netmask> field points to a structure containing the netmask "
201 "associated with I<ifa_addr>, if applicable for the address family. This "
202 "field may contain a null pointer."
203 msgstr ""
204 "Câmpul I<ifa_netmask> indică către o structură care conține masca de rețea "
205 "asociată cu I<ifa_addr>, dacă este cazul pentru familia de adrese. Acest "
206 "câmp poate conține un indicator nul."
207
208 #. type: Plain text
209 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
210 #: mageia-cauldron
211 msgid ""
212 "Depending on whether the bit B<IFF_BROADCAST> or B<IFF_POINTOPOINT> is set "
213 "in I<ifa_flags> (only one can be set at a time), either I<ifa_broadaddr> "
214 "will contain the broadcast address associated with I<ifa_addr> (if "
215 "applicable for the address family) or I<ifa_dstaddr> will contain the "
216 "destination address of the point-to-point interface."
217 msgstr ""
218 "În funcție de starea (activat/dezactivat) a bitului B<IFF_BROADCAST> sau "
219 "B<IFF_POINTOPOINT> în I<ifa_flags> (numai unul poate fi activat la un moment "
220 "dat), I<ifa_broadaddr> va conține adresa de difuzare asociată cu I<ifa_addr> "
221 "(dacă este aplicabilă pentru familia de adrese) sau I<ifa_dstaddr> va "
222 "conține adresa de destinație a interfeței punct-la-punct."
223
224 #. type: Plain text
225 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
226 #: mageia-cauldron
227 msgid ""
228 "The I<ifa_data> field points to a buffer containing address-family-specific "
229 "data; this field may be NULL if there is no such data for this interface."
230 msgstr ""
231 "Câmpul I<ifa_data> indică o memorie tampon care conține date specifice "
232 "familiei de adrese; acest câmp poate fi NULL dacă nu există astfel de date "
233 "pentru această interfață."
234
235 #. type: Plain text
236 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
237 #: mageia-cauldron
238 msgid ""
239 "The data returned by B<getifaddrs>() is dynamically allocated and should be "
240 "freed using B<freeifaddrs>() when no longer needed."
241 msgstr ""
242 "Datele returnate de B<getifaddrs>() sunt alocate dinamic și ar trebui "
243 "eliberate utilizând B<freeifaddrs>() atunci când nu mai sunt necesare."
244
245 #. type: SH
246 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
247 #: mageia-cauldron
248 #, no-wrap
249 msgid "RETURN VALUE"
250 msgstr "VALOAREA RETURNATĂ"
251
252 #. type: Plain text
253 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
254 #: mageia-cauldron
255 msgid ""
256 "On success, B<getifaddrs>() returns zero; on error, -1 is returned, and "
257 "I<errno> is set to indicate the error."
258 msgstr ""
259 "În caz de succes, B<getifaddrs>() returnează zero; în caz de eroare, este "
260 "returnat -1, iar I<errno> este configurată pentru a indica eroarea."
261
262 #. type: SH
263 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
264 #: mageia-cauldron
265 #, no-wrap
266 msgid "ERRORS"
267 msgstr "ERORI-IEȘIRE"
268
269 #. type: Plain text
270 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
271 #: mageia-cauldron
272 msgid ""
273 "B<getifaddrs>() may fail and set I<errno> for any of the errors specified "
274 "for B<socket>(2), B<bind>(2), B<getsockname>(2), B<recvmsg>(2), "
275 "B<sendto>(2), B<malloc>(3), or B<realloc>(3)."
276 msgstr ""
277 "B<getifaddrs>() poate eșua și configura I<errno> pentru oricare dintre "
278 "erorile specificate pentru B<socket>(2), B<bind>(2), B<getsockname>(2), "
279 "B<recvmsg>(2), B<sendto>(2), B<malloc>(3) sau B<realloc>(3)."
280
281 #. type: SH
282 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
283 #: mageia-cauldron
284 #, no-wrap
285 msgid "ATTRIBUTES"
286 msgstr "ATRIBUTE"
287
288 #. type: Plain text
289 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
290 #: mageia-cauldron
291 msgid ""
292 "For an explanation of the terms used in this section, see B<attributes>(7)."
293 msgstr ""
294 "Pentru o explicație a termenilor folosiți în această secțiune, a se vedea "
295 "B<attributes>(7)."
296
297 #. type: tbl table
298 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
299 #: mageia-cauldron
300 #, no-wrap
301 msgid "Interface"
302 msgstr "Interfață"
303
304 #. type: tbl table
305 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
306 #: mageia-cauldron
307 #, no-wrap
308 msgid "Attribute"
309 msgstr "Atribut"
310
311 #. type: tbl table
312 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
313 #: mageia-cauldron
314 #, no-wrap
315 msgid "Value"
316 msgstr "Valoare"
317
318 #. type: tbl table
319 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
320 #: mageia-cauldron
321 #, no-wrap
322 msgid ".na\n"
323 msgstr ".na\n"
324
325 #. type: tbl table
326 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
327 #: mageia-cauldron
328 #, no-wrap
329 msgid ".nh\n"
330 msgstr ".nh\n"
331
332 #. type: tbl table
333 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
334 #: mageia-cauldron
335 #, no-wrap
336 msgid ""
337 "B<getifaddrs>(),\n"
338 "B<freeifaddrs>()"
339 msgstr ""
340 "B<getifaddrs>(),\n"
341 "B<freeifaddrs>()"
342
343 #. type: tbl table
344 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
345 #: mageia-cauldron
346 #, no-wrap
347 msgid "Thread safety"
348 msgstr "Siguranța firelor"
349
350 #. type: tbl table
351 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
352 #: mageia-cauldron
353 #, no-wrap
354 msgid "MT-Safe"
355 msgstr "MT-Safe"
356
357 #. type: SH
358 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
359 #: mageia-cauldron
360 #, no-wrap
361 msgid "STANDARDS"
362 msgstr "STANDARDE"
363
364 #. type: Plain text
365 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
366 #: mageia-cauldron
367 msgid "None."
368 msgstr "Niciunul."
369
370 #. type: SH
371 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
372 #: mageia-cauldron
373 #, no-wrap
374 msgid "HISTORY"
375 msgstr "ISTORIC"
376
377 #. , but the BSD-derived documentation generally
378 #. appears to be confused and obsolete on this point.
379 #. i.e., commonly it still says one of them will be NULL, even if
380 #. the ifa_ifu union is already present
381 #. type: Plain text
382 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
383 #: mageia-cauldron
384 msgid ""
385 "This function first appeared in BSDi and is present on the BSD systems, but "
386 "with slightly different semantics documented\\[em]returning one entry per "
387 "interface, not per address. This means I<ifa_addr> and other fields can "
388 "actually be NULL if the interface has no address, and no link-level address "
389 "is returned if the interface has an IP address assigned. Also, the way of "
390 "choosing either I<ifa_broadaddr> or I<ifa_dstaddr> differs on various "
391 "systems."
392 msgstr ""
393 "Această funcție a apărut pentru prima dată în BSDi și este prezentă pe "
394 "sistemele BSD, dar cu o semantică ușor diferită, documentată-returnând o "
395 "intrare pe interfață, nu pe adresă. Aceasta înseamnă că I<ifa_addr> și alte "
396 "câmpuri pot fi de fapt NULL dacă interfața nu are adresă și nu este "
397 "returnată nicio adresă la nivel de legătură(conexiune) dacă interfața are o "
398 "adresă IP atribuită. De asemenea, modul de alegere a I<ifa_broadaddr> sau "
399 "I<ifa_dstaddr> diferă de la un sistem la altul."
400
401 #. type: Plain text
402 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
403 #: mageia-cauldron
404 msgid ""
405 "B<getifaddrs>() first appeared in glibc 2.3, but before glibc 2.3.3, the "
406 "implementation supported only IPv4 addresses; IPv6 support was added in "
407 "glibc 2.3.3. Support of address families other than IPv4 is available only "
408 "on kernels that support netlink."
409 msgstr ""
410 "B<getifaddrs>() a apărut pentru prima dată în glibc 2.3, dar înainte de "
411 "glibc 2.3.3, implementarea accepta numai adrese IPv4; suportul pentru IPv6 a "
412 "fost adăugat în glibc 2.3.3. Suportul pentru alte familii de adrese decât "
413 "IPv4 este disponibil numai pe nucleele care acceptă netlink."
414
415 #. type: SH
416 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
417 #: mageia-cauldron
418 #, no-wrap
419 msgid "NOTES"
420 msgstr "NOTE"
421
422 #. type: Plain text
423 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
424 #: mageia-cauldron
425 msgid ""
426 "The addresses returned on Linux will usually be the IPv4 and IPv6 addresses "
427 "assigned to the interface, but also one B<AF_PACKET> address per interface "
428 "containing lower-level details about the interface and its physical layer. "
429 "In this case, the I<ifa_data> field may contain a pointer to a I<struct "
430 "rtnl_link_stats>, defined in I<E<lt>linux/if_link.hE<gt>> (in Linux 2.4 and "
431 "earlier, I<struct net_device_stats>, defined in I<E<lt>linux/"
432 "netdevice.hE<gt>>), which contains various interface attributes and "
433 "statistics."
434 msgstr ""
435 "Adresele returnate pe Linux vor fi de obicei adresele IPv4 și IPv6 atribuite "
436 "interfeței, dar și o adresă B<AF_PACKET> pentru fiecare interfață care "
437 "conține detalii de nivel inferior despre interfață și stratul său fizic. În "
438 "acest caz, câmpul I<ifa_data> poate conține un indicator către o structură "
439 "I<struct rtnl_link_stats>, definită în I<E<lt>linux/if_link.hE<gt>> (în "
440 "Linux 2.4 și anterior, I<struct net_device_stats>, definită în I<E<lt>linux/"
441 "netdevice.hE<gt>>), care conține diverse atribute și statistici ale "
442 "interfeței."
443
444 #. type: SH
445 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
446 #: mageia-cauldron
447 #, no-wrap
448 msgid "EXAMPLES"
449 msgstr "EXEMPLE"
450
451 #. type: Plain text
452 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
453 #: mageia-cauldron
454 msgid ""
455 "The program below demonstrates the use of B<getifaddrs>(), B<freeifaddrs>(), "
456 "and B<getnameinfo>(3). Here is what we see when running this program on one "
457 "system:"
458 msgstr ""
459 "Programul de mai jos demonstrează utilizarea B<getifaddrs>(), "
460 "B<freeifaddrs>() și B<getnameinfo>(3). Iată ce vedem la rularea acestui "
461 "program pe un sistem:"
462
463 #. type: Plain text
464 #: archlinux debian-unstable mageia-cauldron
465 #, no-wrap
466 msgid ""
467 "$B< ./a.out>;\n"
468 "lo AF_PACKET (17)\n"
469 " tx_packets = 524; rx_packets = 524\n"
470 " tx_bytes = 38788; rx_bytes = 38788\n"
471 "wlp3s0 AF_PACKET (17)\n"
472 " tx_packets = 108391; rx_packets = 130245\n"
473 " tx_bytes = 30420659; rx_bytes = 94230014\n"
474 "em1 AF_PACKET (17)\n"
475 " tx_packets = 0; rx_packets = 0\n"
476 " tx_bytes = 0; rx_bytes = 0\n"
477 "lo AF_INET (2)\n"
478 " address: E<lt>127.0.0.1E<gt>\n"
479 "wlp3s0 AF_INET (2)\n"
480 " address: E<lt>192.168.235.137E<gt>\n"
481 "lo AF_INET6 (10)\n"
482 " address: E<lt>::1E<gt>\n"
483 "wlp3s0 AF_INET6 (10)\n"
484 " address: E<lt>fe80::7ee9:d3ff:fef5:1a91%wlp3s0E<gt>\n"
485 msgstr ""
486 "$B< ./a.out>;\n"
487 "lo AF_PACKET (17)\n"
488 " tx_packets = 524; rx_packets = 524\n"
489 " tx_bytes = 38788; rx_bytes = 38788\n"
490 "wlp3s0 AF_PACKET (17)\n"
491 " tx_packets = 108391; rx_packets = 130245\n"
492 " tx_bytes = 30420659; rx_bytes = 94230014\n"
493 "em1 AF_PACKET (17)\n"
494 " tx_packets = 0; rx_packets = 0\n"
495 " tx_bytes = 0; rx_bytes = 0\n"
496 "lo AF_INET (2)\n"
497 " address: E<lt>127.0.0.1E<gt>\n"
498 "wlp3s0 AF_INET (2)\n"
499 " address: E<lt>192.168.235.137E<gt>\n"
500 "lo AF_INET6 (10)\n"
501 " address: E<lt>::1E<gt>\n"
502 "wlp3s0 AF_INET6 (10)\n"
503 " address: E<lt>fe80::7ee9:d3ff:fef5:1a91%wlp3s0E<gt>\n"
504
505 #. type: SS
506 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
507 #: mageia-cauldron
508 #, no-wrap
509 msgid "Program source"
510 msgstr "Sursa programului"
511
512 #. type: Plain text
513 #: archlinux debian-unstable mageia-cauldron
514 #, no-wrap
515 msgid ""
516 "#define _GNU_SOURCE /* To get defns of NI_MAXSERV and NI_MAXHOST */\n"
517 "#include E<lt>arpa/inet.hE<gt>\n"
518 "#include E<lt>sys/socket.hE<gt>\n"
519 "#include E<lt>netdb.hE<gt>\n"
520 "#include E<lt>ifaddrs.hE<gt>\n"
521 "#include E<lt>stdio.hE<gt>\n"
522 "#include E<lt>stdlib.hE<gt>\n"
523 "#include E<lt>unistd.hE<gt>\n"
524 "#include E<lt>linux/if_link.hE<gt>\n"
525 "\\&\n"
526 "int main(int argc, char *argv[])\n"
527 "{\n"
528 " struct ifaddrs *ifaddr;\n"
529 " int family, s;\n"
530 " char host[NI_MAXHOST];\n"
531 "\\&\n"
532 " if (getifaddrs(&ifaddr) == -1) {\n"
533 " perror(\"getifaddrs\");\n"
534 " exit(EXIT_FAILURE);\n"
535 " }\n"
536 "\\&\n"
537 " /* Walk through linked list, maintaining head pointer so we\n"
538 " can free list later. */\n"
539 "\\&\n"
540 " for (struct ifaddrs *ifa = ifaddr; ifa != NULL;\n"
541 " ifa = ifa-E<gt>ifa_next) {\n"
542 " if (ifa-E<gt>ifa_addr == NULL)\n"
543 " continue;\n"
544 "\\&\n"
545 " family = ifa-E<gt>ifa_addr-E<gt>sa_family;\n"
546 "\\&\n"
547 " /* Display interface name and family (including symbolic\n"
548 " form of the latter for the common families). */\n"
549 "\\&\n"
550 " printf(\"%-8s %s (%d)\\[rs]n\",\n"
551 " ifa-E<gt>ifa_name,\n"
552 " (family == AF_PACKET) ? \"AF_PACKET\" :\n"
553 " (family == AF_INET) ? \"AF_INET\" :\n"
554 " (family == AF_INET6) ? \"AF_INET6\" : \"???\",\n"
555 " family);\n"
556 "\\&\n"
557 " /* For an AF_INET* interface address, display the address. */\n"
558 "\\&\n"
559 " if (family == AF_INET || family == AF_INET6) {\n"
560 " s = getnameinfo(ifa-E<gt>ifa_addr,\n"
561 " (family == AF_INET) ? sizeof(struct sockaddr_in) :\n"
562 " sizeof(struct sockaddr_in6),\n"
563 " host, NI_MAXHOST,\n"
564 " NULL, 0, NI_NUMERICHOST);\n"
565 " if (s != 0) {\n"
566 " printf(\"getnameinfo() failed: %s\\[rs]n\", gai_strerror(s));\n"
567 " exit(EXIT_FAILURE);\n"
568 " }\n"
569 "\\&\n"
570 " printf(\"\\[rs]t\\[rs]taddress: E<lt>%sE<gt>\\[rs]n\", host);\n"
571 "\\&\n"
572 " } else if (family == AF_PACKET && ifa-E<gt>ifa_data != NULL) {\n"
573 " struct rtnl_link_stats *stats = ifa-E<gt>ifa_data;\n"
574 "\\&\n"
575 " printf(\"\\[rs]t\\[rs]ttx_packets = %10u; rx_packets = %10u\\[rs]n\"\n"
576 " \"\\[rs]t\\[rs]ttx_bytes = %10u; rx_bytes = %10u\\[rs]n\",\n"
577 " stats-E<gt>tx_packets, stats-E<gt>rx_packets,\n"
578 " stats-E<gt>tx_bytes, stats-E<gt>rx_bytes);\n"
579 " }\n"
580 " }\n"
581 "\\&\n"
582 " freeifaddrs(ifaddr);\n"
583 " exit(EXIT_SUCCESS);\n"
584 "}\n"
585 msgstr ""
586 "#define _GNU_SOURCE /* Pentru a obține definițiile NI_MAXSERV și NI_MAXHOST */\n"
587 "#include E<lt>arpa/inet.hE<gt>\n"
588 "#include E<lt>sys/socket.hE<gt>\n"
589 "#include E<lt>netdb.hE<gt>\n"
590 "#include E<lt>ifaddrs.hE<gt>\n"
591 "#include E<lt>stdio.hE<gt>\n"
592 "#include E<lt>stdlib.hE<gt>\n"
593 "#include E<lt>unistd.hE<gt>\n"
594 "#include E<lt>linux/if_link.hE<gt>\n"
595 "\\&\n"
596 "int main(int argc, char *argv[])\n"
597 "{\n"
598 " struct ifaddrs *ifaddr;\n"
599 " int family, s;\n"
600 " char host[NI_MAXHOST];\n"
601 "\\&\n"
602 " if (getifaddrs(&ifaddr) == -1) {\n"
603 " perror(\"getifaddrs\");\n"
604 " exit(EXIT_FAILURE);\n"
605 " }\n"
606 "\\&\n"
607 " /* Parcurgem lista legată, menținând indicatorul capului,\n"
608 " astfel încât să putem elibera lista mai târziu. */\n"
609 "\\&\n"
610 " for (struct ifaddrs *ifa = ifaddr; ifa != NULL;\n"
611 " ifa = ifa-E<gt>ifa_next) {\n"
612 " if (ifa-E<gt>ifa_addr == NULL)\n"
613 " continue;\n"
614 "\\&\n"
615 " family = ifa-E<gt>ifa_addr-E<gt>sa_family;\n"
616 "\\&\n"
617 " /* Afișează numele și familia interfeței (inclusiv forma\n"
618 " simbolică a acesteia din urmă pentru familiile comune). */\n"
619 "\\&\n"
620 " printf(\"%-8s %s (%d)\\[rs]n\",\n"
621 " ifa-E<gt>ifa_name,\n"
622 " (family == AF_PACKET) ? \"AF_PACKET\" :\n"
623 " (family == AF_INET) ? \"AF_INET\" :\n"
624 " (family == AF_INET6) ? \"AF_INET6\" : \"???\",\n"
625 " family);\n"
626 "\\&\n"
627 " /* Pentru o adresă de interfață AF_INET*, afișează adresa. */\n"
628 "\\&\n"
629 " if (family == AF_INET || family == AF_INET6) {\n"
630 " s = getnameinfo(ifa-E<gt>ifa_addr,\n"
631 " (family == AF_INET) ? sizeof(struct sockaddr_in) :\n"
632 " sizeof(struct sockaddr_in6),\n"
633 " host, NI_MAXHOST,\n"
634 " NULL, 0, NI_NUMERICHOST);\n"
635 " if (s != 0) {\n"
636 " printf(\"getnameinfo() a eșuat: %s\\[rs]n\", gai_strerror(s));\n"
637 " exit(EXIT_FAILURE);\n"
638 " }\n"
639 "\\&\n"
640 " printf(\"\\[rs]t\\[rs]tadresa: E<lt>%sE<gt>\\[rs]n\", host);\n"
641 "\\&\n"
642 " } else if (family == AF_PACKET && ifa-E<gt>ifa_data != NULL) {\n"
643 " struct rtnl_link_stats *stats = ifa-E<gt>ifa_data;\n"
644 "\\&\n"
645 " printf(\"\\[rs]t\\[rs]ttx_packets = %10u; rx_packets = %10u\\[rs]n\"\n"
646 " \"\\[rs]t\\[rs]ttx_bytes = %10u; rx_bytes = %10u\\[rs]n\",\n"
647 " stats-E<gt>tx_packets, stats-E<gt>rx_packets,\n"
648 " stats-E<gt>tx_bytes, stats-E<gt>rx_bytes);\n"
649 " }\n"
650 " }\n"
651 "\\&\n"
652 " freeifaddrs(ifaddr);\n"
653 " exit(EXIT_SUCCESS);\n"
654 "}\n"
655
656 #. type: SH
657 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
658 #: mageia-cauldron
659 #, no-wrap
660 msgid "SEE ALSO"
661 msgstr "CONSULTAȚI ȘI"
662
663 #. type: Plain text
664 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
665 #: mageia-cauldron
666 msgid ""
667 "B<bind>(2), B<getsockname>(2), B<socket>(2), B<packet>(7), B<ifconfig>(8)"
668 msgstr ""
669 "B<bind>(2), B<getsockname>(2), B<socket>(2), B<packet>(7), B<ifconfig>(8)"
670
671 #. type: TH
672 #: debian-trixie
673 #, no-wrap
674 msgid "2024-06-15"
675 msgstr "15 iunie 2024"
676
677 #. type: TH
678 #: debian-trixie
679 #, no-wrap
680 msgid "Linux man-pages 6.9.1"
681 msgstr "Pagini de manual de Linux 6.9.1"
682
683 #. type: Plain text
684 #: debian-trixie
685 msgid "Standard C library (I<libc>, I<-lc>)"
686 msgstr "Biblioteca C standard (I<libc>, I<-lc>)"
687
688 #. type: Plain text
689 #: debian-trixie fedora-44 fedora-rawhide
690 #, no-wrap
691 msgid ""
692 "$ B<./a.out>\n"
693 "lo AF_PACKET (17)\n"
694 " tx_packets = 524; rx_packets = 524\n"
695 " tx_bytes = 38788; rx_bytes = 38788\n"
696 "wlp3s0 AF_PACKET (17)\n"
697 " tx_packets = 108391; rx_packets = 130245\n"
698 " tx_bytes = 30420659; rx_bytes = 94230014\n"
699 "em1 AF_PACKET (17)\n"
700 " tx_packets = 0; rx_packets = 0\n"
701 " tx_bytes = 0; rx_bytes = 0\n"
702 "lo AF_INET (2)\n"
703 " address: E<lt>127.0.0.1E<gt>\n"
704 "wlp3s0 AF_INET (2)\n"
705 " address: E<lt>192.168.235.137E<gt>\n"
706 "lo AF_INET6 (10)\n"
707 " address: E<lt>::1E<gt>\n"
708 "wlp3s0 AF_INET6 (10)\n"
709 " address: E<lt>fe80::7ee9:d3ff:fef5:1a91%wlp3s0E<gt>\n"
710 msgstr ""
711 "$ B<./a.out>\n"
712 "lo AF_PACKET (17)\n"
713 " tx_packets = 524; rx_packets = 524\n"
714 " tx_bytes = 38788; rx_bytes = 38788\n"
715 "wlp3s0 AF_PACKET (17)\n"
716 " tx_packets = 108391; rx_packets = 130245\n"
717 " tx_bytes = 30420659; rx_bytes = 94230014\n"
718 "em1 AF_PACKET (17)\n"
719 " tx_packets = 0; rx_packets = 0\n"
720 " tx_bytes = 0; rx_bytes = 0\n"
721 "lo AF_INET (2)\n"
722 " address: E<lt>127.0.0.1E<gt>\n"
723 "wlp3s0 AF_INET (2)\n"
724 " address: E<lt>192.168.235.137E<gt>\n"
725 "lo AF_INET6 (10)\n"
726 " address: E<lt>::1E<gt>\n"
727 "wlp3s0 AF_INET6 (10)\n"
728 " address: E<lt>fe80::7ee9:d3ff:fef5:1a91%wlp3s0E<gt>\n"
729
730 #. type: Plain text
731 #: debian-trixie fedora-44 fedora-rawhide
732 #, no-wrap
733 msgid ""
734 "#define _GNU_SOURCE /* To get defns of NI_MAXSERV and NI_MAXHOST */\n"
735 "#include E<lt>arpa/inet.hE<gt>\n"
736 "#include E<lt>sys/socket.hE<gt>\n"
737 "#include E<lt>netdb.hE<gt>\n"
738 "#include E<lt>ifaddrs.hE<gt>\n"
739 "#include E<lt>stdio.hE<gt>\n"
740 "#include E<lt>stdlib.hE<gt>\n"
741 "#include E<lt>unistd.hE<gt>\n"
742 "#include E<lt>linux/if_link.hE<gt>\n"
743 "\\&\n"
744 "int main(int argc, char *argv[])\n"
745 "{\n"
746 " struct ifaddrs *ifaddr;\n"
747 " int family, s;\n"
748 " char host[NI_MAXHOST];\n"
749 "\\&\n"
750 " if (getifaddrs(&ifaddr) == -1) {\n"
751 " perror(\"getifaddrs\");\n"
752 " exit(EXIT_FAILURE);\n"
753 " }\n"
754 "\\&\n"
755 " /* Walk through linked list, maintaining head pointer so we\n"
756 " can free list later. */\n"
757 "\\&\n"
758 " for (struct ifaddrs *ifa = ifaddr; ifa != NULL;\n"
759 " ifa = ifa-E<gt>ifa_next) {\n"
760 " if (ifa-E<gt>ifa_addr == NULL)\n"
761 " continue;\n"
762 "\\&\n"
763 " family = ifa-E<gt>ifa_addr-E<gt>sa_family;\n"
764 "\\&\n"
765 " /* Display interface name and family (including symbolic\n"
766 " form of the latter for the common families). */\n"
767 "\\&\n"
768 " printf(\"%-8s %s (%d)\\[rs]n\",\n"
769 " ifa-E<gt>ifa_name,\n"
770 " (family == AF_PACKET) ? \"AF_PACKET\" :\n"
771 " (family == AF_INET) ? \"AF_INET\" :\n"
772 " (family == AF_INET6) ? \"AF_INET6\" : \"???\",\n"
773 " family);\n"
774 "\\&\n"
775 " /* For an AF_INET* interface address, display the address. */\n"
776 "\\&\n"
777 " if (family == AF_INET || family == AF_INET6) {\n"
778 " s = getnameinfo(ifa-E<gt>ifa_addr,\n"
779 " (family == AF_INET) ? sizeof(struct sockaddr_in) :\n"
780 " sizeof(struct sockaddr_in6),\n"
781 " host, NI_MAXHOST,\n"
782 " NULL, 0, NI_NUMERICHOST);\n"
783 " if (s != 0) {\n"
784 " printf(\"getnameinfo() failed: %s\\[rs]n\", gai_strerror(s));\n"
785 " exit(EXIT_FAILURE);\n"
786 " }\n"
787 "\\&\n"
788 " printf(\"\\[rs]t\\[rs]taddress: E<lt>%sE<gt>\\[rs]n\", host);\n"
789 "\\&\n"
790 " } else if (family == AF_PACKET && ifa-E<gt>ifa_data != NULL) {\n"
791 " struct rtnl_link_stats *stats = ifa-E<gt>ifa_data;\n"
792 "\\&\n"
793 " printf(\"\\[rs]t\\[rs]ttx_packets = %10u; rx_packets = %10u\\[rs]n\"\n"
794 " \"\\[rs]t\\[rs]ttx_bytes = %10u; rx_bytes = %10u\\[rs]n\",\n"
795 " stats-E<gt>tx_packets, stats-E<gt>rx_packets,\n"
796 " stats-E<gt>tx_bytes, stats-E<gt>rx_bytes);\n"
797 " }\n"
798 " }\n"
799 "\\&\n"
800 " freeifaddrs(ifaddr);\n"
801 " exit(EXIT_SUCCESS);\n"
802 "}\n"
803 msgstr ""
804 "#define _GNU_SOURCE /* Pentru a obține definițiile NI_MAXSERV și NI_MAXHOST */\n"
805 "#include E<lt>arpa/inet.hE<gt>\n"
806 "#include E<lt>sys/socket.hE<gt>\n"
807 "#include E<lt>netdb.hE<gt>\n"
808 "#include E<lt>ifaddrs.hE<gt>\n"
809 "#include E<lt>stdio.hE<gt>\n"
810 "#include E<lt>stdlib.hE<gt>\n"
811 "#include E<lt>unistd.hE<gt>\n"
812 "#include E<lt>linux/if_link.hE<gt>\n"
813 "\\&\n"
814 "int main(int argc, char *argv[])\n"
815 "{\n"
816 " struct ifaddrs *ifaddr;\n"
817 " int family, s;\n"
818 " char host[NI_MAXHOST];\n"
819 "\\&\n"
820 " if (getifaddrs(&ifaddr) == -1) {\n"
821 " perror(\"getifaddrs\");\n"
822 " exit(EXIT_FAILURE);\n"
823 " }\n"
824 "\\&\n"
825 " /* Parcurgem lista legată, menținând indicatorul capului,\n"
826 " astfel încât să putem elibera lista mai târziu. */\n"
827 "\\&\n"
828 " for (struct ifaddrs *ifa = ifaddr; ifa != NULL;\n"
829 " ifa = ifa-E<gt>ifa_next) {\n"
830 " if (ifa-E<gt>ifa_addr == NULL)\n"
831 " continue;\n"
832 "\\&\n"
833 " family = ifa-E<gt>ifa_addr-E<gt>sa_family;\n"
834 "\\&\n"
835 " /* Afișează numele și familia interfeței (inclusiv forma\n"
836 " simbolică a acesteia din urmă pentru familiile comune). */\n"
837 "\\&\n"
838 " printf(\"%-8s %s (%d)\\[rs]n\",\n"
839 " ifa-E<gt>ifa_name,\n"
840 " (family == AF_PACKET) ? \"AF_PACKET\" :\n"
841 " (family == AF_INET) ? \"AF_INET\" :\n"
842 " (family == AF_INET6) ? \"AF_INET6\" : \"???\",\n"
843 " family);\n"
844 "\\&\n"
845 " /* Pentru o adresă de interfață AF_INET*, afișează adresa. */\n"
846 "\\&\n"
847 " if (family == AF_INET || family == AF_INET6) {\n"
848 " s = getnameinfo(ifa-E<gt>ifa_addr,\n"
849 " (family == AF_INET) ? sizeof(struct sockaddr_in) :\n"
850 " sizeof(struct sockaddr_in6),\n"
851 " host, NI_MAXHOST,\n"
852 " NULL, 0, NI_NUMERICHOST);\n"
853 " if (s != 0) {\n"
854 " printf(\"getnameinfo() a eșuat: %s\\[rs]n\", gai_strerror(s));\n"
855 " exit(EXIT_FAILURE);\n"
856 " }\n"
857 "\\&\n"
858 " printf(\"\\[rs]t\\[rs]tadresa: E<lt>%sE<gt>\\[rs]n\", host);\n"
859 "\\&\n"
860 " } else if (family == AF_PACKET && ifa-E<gt>ifa_data != NULL) {\n"
861 " struct rtnl_link_stats *stats = ifa-E<gt>ifa_data;\n"
862 "\\&\n"
863 " printf(\"\\[rs]t\\[rs]ttx_packets = %10u; rx_packets = %10u\\[rs]n\"\n"
864 " \"\\[rs]t\\[rs]ttx_bytes = %10u; rx_bytes = %10u\\[rs]n\",\n"
865 " stats-E<gt>tx_packets, stats-E<gt>rx_packets,\n"
866 " stats-E<gt>tx_bytes, stats-E<gt>rx_bytes);\n"
867 " }\n"
868 " }\n"
869 "\\&\n"
870 " freeifaddrs(ifaddr);\n"
871 " exit(EXIT_SUCCESS);\n"
872 "}\n"
873
874 #. type: TH
875 #: fedora-44 fedora-rawhide
876 #, no-wrap
877 msgid "2024-07-23"
878 msgstr "23 iulie 2024"
879
880 #. type: TH
881 #: fedora-44 fedora-rawhide
882 #, no-wrap
883 msgid "Linux man-pages 6.13"
884 msgstr "Pagini de manual de Linux 6.13"
885
886 #. type: TH
887 #: mageia-cauldron
888 #, no-wrap
889 msgid "Linux man-pages 6.17"
890 msgstr "Pagini de manual de Linux 6.17"