Debian Codegraph @

po/pl/man2/select.2.po

raw
1 # Polish translation of manpages
2 # This file is distributed under the same license as the manpages-l10n package.
3 # Copyright © of this file:
4 # Przemek Borys <[email protected]>, 1999.
5 # Robert Luberda <[email protected]>, 2006, 2012, 2013.
6 # Michał Kułach <[email protected]>, 2013, 2014, 2016, 2024, 2025.
7 msgid ""
8 msgstr ""
9 "Project-Id-Version: manpages-pl\n"
10 "POT-Creation-Date: 2026-06-05 06:42+0200\n"
11 "PO-Revision-Date: 2025-11-26 20:54+0100\n"
12 "Last-Translator: Michał Kułach <[email protected]>\n"
13 "Language-Team: Polish <[email protected]>\n"
14 "Language: pl\n"
15 "MIME-Version: 1.0\n"
16 "Content-Type: text/plain; charset=UTF-8\n"
17 "Content-Transfer-Encoding: 8bit\n"
18 "X-Generator: Lokalize 25.04.0\n"
19 "Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 "
20 "|| n%100>=20) ? 1 : 2);\n"
21
22 #. type: TH
23 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
24 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
25 #, no-wrap
26 msgid "select"
27 msgstr "select"
28
29 #. type: TH
30 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
31 #: opensuse-tumbleweed
32 #, no-wrap
33 msgid "2026-02-08"
34 msgstr "8 lutego 2026 r."
35
36 #. type: TH
37 #: archlinux debian-unstable
38 #, no-wrap
39 msgid "Linux man-pages 6.18"
40 msgstr "Linux man-pages 6.18"
41
42 #. type: SH
43 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
44 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
45 #, no-wrap
46 msgid "NAME"
47 msgstr "NAZWA"
48
49 #. type: Plain text
50 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
51 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
52 msgid ""
53 "select, pselect, FD_CLR, FD_ISSET, FD_SET, FD_ZERO, fd_set - synchronous I/O "
54 "multiplexing"
55 msgstr ""
56 "select, pselect, FD_CLR, FD_ISSET, FD_SET, FD_ZERO, fd_set - synchronicznie "
57 "zwielokrotnia wejście/wyjście"
58
59 #. type: SH
60 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
61 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
62 #, no-wrap
63 msgid "LIBRARY"
64 msgstr "BIBLIOTEKA"
65
66 #. type: Plain text
67 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
68 #: opensuse-leap-16-1 opensuse-tumbleweed
69 msgid "Standard C library (I<libc>,\\ I<-lc>)"
70 msgstr "Standardowa biblioteka C (I<libc>,\\ I<-lc>)"
71
72 #. type: SH
73 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
74 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
75 #, no-wrap
76 msgid "SYNOPSIS"
77 msgstr "SKŁADNIA"
78
79 #. type: Plain text
80 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
81 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
82 #, no-wrap
83 msgid "B<#include E<lt>sys/select.hE<gt>>\n"
84 msgstr "B<#include E<lt>sys/select.hE<gt>>\n"
85
86 #. type: Plain text
87 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
88 #: opensuse-tumbleweed
89 #, no-wrap
90 msgid "B<typedef> /* .\\|.\\|.\\& */ B<fd_set;>\n"
91 msgstr "B<typedef> /* .\\|.\\|.\\& */ B<fd_set;>\n"
92
93 #. type: Plain text
94 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
95 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
96 #, no-wrap
97 msgid ""
98 "B<int select(int >I<nfds>B<, fd_set *_Nullable restrict >I<readfds>B<,>\n"
99 "B< fd_set *_Nullable restrict >I<writefds>B<,>\n"
100 "B< fd_set *_Nullable restrict >I<exceptfds>B<,>\n"
101 "B< struct timeval *_Nullable restrict >I<timeout>B<);>\n"
102 msgstr ""
103 "B<int select(int >I<nfds>B<, fd_set *_Nullable restrict >I<readfds>B<,>\n"
104 "B< fd_set *_Nullable restrict >I<writefds>B<,>\n"
105 "B< fd_set *_Nullable restrict >I<exceptfds>B<,>\n"
106 "B< struct timeval *_Nullable restrict >I<timeout>B<);>\n"
107
108 #. type: Plain text
109 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
110 #: opensuse-tumbleweed
111 #, no-wrap
112 msgid ""
113 "B<void FD_CLR(int >I<fd>B<, fd_set *>I<set>B<);>\n"
114 "B<int FD_ISSET(int >I<fd>B<, const fd_set *>I<set>B<);>\n"
115 "B<void FD_SET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
116 "B<void FD_ZERO(fd_set *>I<set>B<);>\n"
117 msgstr ""
118 "B<void FD_CLR(int >I<fd>B<, fd_set *>I<set>B<);>\n"
119 "B<int FD_ISSET(int >I<fd>B<, const fd_set *>I<set>B<);>\n"
120 "B<void FD_SET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
121 "B<void FD_ZERO(fd_set *>I<set>B<);>\n"
122
123 #. type: Plain text
124 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
125 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
126 #, no-wrap
127 msgid ""
128 "B<int pselect(int >I<nfds>B<, fd_set *_Nullable restrict >I<readfds>B<,>\n"
129 "B< fd_set *_Nullable restrict >I<writefds>B<,>\n"
130 "B< fd_set *_Nullable restrict >I<exceptfds>B<,>\n"
131 "B< const struct timespec *_Nullable restrict >I<timeout>B<,>\n"
132 "B< const sigset_t *_Nullable restrict >I<sigmask>B<);>\n"
133 msgstr ""
134 "B<int pselect(int >I<nfds>B<, fd_set *_Nullable restrict >I<readfds>B<,>\n"
135 "B< fd_set *_Nullable restrict >I<writefds>B<,>\n"
136 "B< fd_set *_Nullable restrict >I<exceptfds>B<,>\n"
137 "B< const struct timespec *_Nullable restrict >I<timeout>B<,>\n"
138 "B< const sigset_t *_Nullable restrict >I<sigmask>B<);>\n"
139
140 #. type: Plain text
141 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
142 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
143 msgid ""
144 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
145 msgstr ""
146 "Wymagane ustawienia makr biblioteki glibc (patrz B<feature_test_macros>(7)):"
147
148 #. type: Plain text
149 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
150 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
151 msgid "B<pselect>():"
152 msgstr "B<pselect>():"
153
154 #. type: Plain text
155 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
156 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
157 #, no-wrap
158 msgid " _POSIX_C_SOURCE E<gt>= 200112L\n"
159 msgstr " _POSIX_C_SOURCE E<gt>= 200112L\n"
160
161 #. type: SH
162 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
163 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
164 #, no-wrap
165 msgid "DESCRIPTION"
166 msgstr "OPIS"
167
168 #. type: Plain text
169 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
170 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
171 msgid ""
172 "B<WARNING>: B<select>() can monitor only file descriptors numbers that are "
173 "less than B<FD_SETSIZE> (1024)\\[em]an unreasonably low limit for many "
174 "modern applications\\[em]and this limitation will not change. All modern "
175 "applications should instead use B<poll>(2) or B<epoll>(7), which do not "
176 "suffer this limitation."
177 msgstr ""
178 "B<OSTRZEŻENIE>: B<select>() potrafi monitorować deskryptory plików o "
179 "numerach mniejszych niż B<FD_SETSIZE> (1024) \\[em] limit nierozsądnie "
180 "niewielki dla wielu współczesnych aplikacji \\[em] i ograniczenie to nie "
181 "zmieni się. Wszystkie współczesne aplikacje powinny w zamian korzystać z "
182 "B<poll>(2) lub B<epoll>(7), które nie mają tego ograniczenia."
183
184 #. type: Plain text
185 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
186 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
187 msgid ""
188 "B<select>() allows a program to monitor multiple file descriptors, waiting "
189 "until one or more of the file descriptors become \"ready\" for some class of "
190 "I/O operation (e.g., input possible). A file descriptor is considered ready "
191 "if it is possible to perform a corresponding I/O operation (e.g., "
192 "B<read>(2), or a sufficiently small B<write>(2)) without blocking."
193 msgstr ""
194 "B<select>() umożliwia programowi monitorowanie wielu deskryptorów plików i "
195 "oczekiwanie aż jeden lub więcej deskryptorów będzie \\[Bq]gotowy\\[rq] na "
196 "wykonanie pewnej klasy operacji wejścia/wyjścia (np. możliwy odczyt). "
197 "Deskryptor pliku jest uważany za gotowy, jeżeli możliwe jest wykonanie "
198 "odpowiadającej operacji wejścia/wyjścia (np. B<read>(2) lub odpowiednio małe "
199 "B<write>(2)) bez blokowania."
200
201 #. type: SS
202 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
203 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
204 #, no-wrap
205 msgid "fd_set"
206 msgstr "fd_set"
207
208 #. type: Plain text
209 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
210 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
211 msgid ""
212 "A structure type that can represent a set of file descriptors. According to "
213 "POSIX, the maximum number of file descriptors in an I<fd_set> structure is "
214 "the value of the macro B<FD_SETSIZE>."
215 msgstr ""
216 "Typ struktury mogącej reprezentować zbiór deskryptorów pliku. Zgodnie z "
217 "POSIX, maksymalną liczbą deskryptorów pliku w strukturze I<fd_set> jest "
218 "wartość makra B<FD_SETSIZE>."
219
220 #. type: SS
221 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
222 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
223 #, no-wrap
224 msgid "File descriptor sets"
225 msgstr "Zbiory deskryptorów pliku"
226
227 #. type: Plain text
228 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
229 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
230 msgid ""
231 "The principal arguments of B<select>() are three \"sets\" of file "
232 "descriptors (declared with the type I<fd_set>), which allow the caller to "
233 "wait for three classes of events on the specified set of file descriptors. "
234 "Each of the I<fd_set> arguments may be specified as NULL if no file "
235 "descriptors are to be watched for the corresponding class of events."
236 msgstr ""
237 "Podstawowymi argumentami B<select>() są trzy \\[Bq]zbiory\\[rq] deskryptorów "
238 "pliku (zadeklarowane jako typ I<fd_set>), pozwalające wywołującemu na "
239 "oczekiwanie na trzy klasy zdarzeń na zadanym zbiorze deskryptorów pliku. "
240 "Każdy argument I<fd_set> można podać jako NULL, jeśli dla odpowiadającej "
241 "klasy zdarzeń nie mają być monitorowane deskryptory pliku."
242
243 #. type: Plain text
244 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
245 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
246 msgid ""
247 "B<Note well>: Upon return, each of the file descriptor sets is modified in "
248 "place to indicate which file descriptors are currently \"ready\". Thus, if "
249 "using B<select>() within a loop, the sets I<must be reinitialized> before "
250 "each call."
251 msgstr ""
252 "B<Proszę zwrócić szczególną uwagę>: Po powrocie, każdy ze zbiorów "
253 "deskryptorów pliku jest modyfikowany w miejscu, aby wskazać, które z "
254 "deskryptorów pliku są aktualnie \\[Bq]gotowe\\[rq]. Z tego względu, jeśli "
255 "B<select>() jest używany w pętli, zbiory I<muszą być zainicjowane ponownie> "
256 "przed każdym wywołaniem."
257
258 #. type: Plain text
259 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
260 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
261 msgid ""
262 "The contents of a file descriptor set can be manipulated using the following "
263 "macros:"
264 msgstr ""
265 "Zawartością zbiorów deskryptorów pliku można manipulować za pomocą "
266 "następujących makr:"
267
268 #. type: TP
269 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
270 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
271 #, no-wrap
272 msgid "B<FD_ZERO>()"
273 msgstr "B<FD_ZERO>()"
274
275 #. type: Plain text
276 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
277 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
278 msgid ""
279 "This macro clears (removes all file descriptors from) I<set>. It should be "
280 "employed as the first step in initializing a file descriptor set."
281 msgstr ""
282 "Makro czyści (usuwa z niego wszystkie deskryptory pliku) I<set>. Powinno być "
283 "użyte jako pierwszy krok w inicjowaniu zbiorów deskryptorów pliku."
284
285 #. type: TP
286 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
287 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
288 #, no-wrap
289 msgid "B<FD_SET>()"
290 msgstr "B<FD_SET>()"
291
292 #. type: Plain text
293 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
294 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
295 msgid ""
296 "This macro adds the file descriptor I<fd> to I<set>. Adding a file "
297 "descriptor that is already present in the set is a no-op, and does not "
298 "produce an error."
299 msgstr ""
300 "Makro dodaje deskryptor pliku I<fd> do zbioru I<set>. Dodanie deskryptora "
301 "pliku, który jest już obecny w zbiorze, jest instrukcją pustą i nie powoduje "
302 "błędu."
303
304 #. type: TP
305 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
306 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
307 #, no-wrap
308 msgid "B<FD_CLR>()"
309 msgstr "B<FD_CLR>()"
310
311 #. type: Plain text
312 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
313 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
314 msgid ""
315 "This macro removes the file descriptor I<fd> from I<set>. Removing a file "
316 "descriptor that is not present in the set is a no-op, and does not produce "
317 "an error."
318 msgstr ""
319 "Makro usuwa deskryptor pliku I<fd> z zbioru I<set>. Usunięcie deskryptora "
320 "pliku, który nie jest obecny w zbiorze jest instrukcją pustą i nie powoduje "
321 "błędu."
322
323 #. type: TP
324 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
325 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
326 #, no-wrap
327 msgid "B<FD_ISSET>()"
328 msgstr "B<FD_ISSET>()"
329
330 #. type: Plain text
331 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
332 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
333 msgid ""
334 "B<select>() modifies the contents of the sets according to the rules "
335 "described below. After calling B<select>(), the B<FD_ISSET>() macro can be "
336 "used to test if a file descriptor is still present in a set. B<FD_ISSET>() "
337 "returns nonzero if the file descriptor I<fd> is present in I<set>, and zero "
338 "if it is not."
339 msgstr ""
340 "B<select>() modyfikuje zawartość zbiorów, zgodnie z regułami opisanymi "
341 "niżej. Po wywołaniu B<select>(), można skorzystać z makra B<FD_ISSET>(), aby "
342 "sprawdzić, czy deskryptor pliku jest wciąż obecny w zbiorze. B<FD_ISSET>() "
343 "zwraca wartość niezerową, jeśli deskryptor pliku I<fd> jest obecny w zbiorze "
344 "I<set> i zero, gdy nie jest."
345
346 #. type: SS
347 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
348 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
349 #, no-wrap
350 msgid "Arguments"
351 msgstr "Argumenty"
352
353 #. type: Plain text
354 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
355 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
356 msgid "The arguments of B<select>() are as follows:"
357 msgstr "Argumenty B<select>() są następujące:"
358
359 #. type: TP
360 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
361 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
362 #, no-wrap
363 msgid "I<readfds>"
364 msgstr "I<readfds>"
365
366 #. type: Plain text
367 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
368 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
369 msgid ""
370 "The file descriptors in this set are watched to see if they are ready for "
371 "reading. A file descriptor is ready for reading if a read operation will "
372 "not block; in particular, a file descriptor is also ready on end-of-file."
373 msgstr ""
374 "Deskryptory pliku w tym zbiorze są monitorowane, aby sprawdzić, czy są "
375 "gotowe do odczytu. Deskryptor pliku jest gotowy do odczytu, jeśli operacja "
376 "odczytu nie będzie blokowała; w szczególności, deskryptor pliku jest również "
377 "gotowy na końcu pliku."
378
379 #. type: Plain text
380 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
381 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
382 msgid ""
383 "After B<select>() has returned, I<readfds> will be cleared of all file "
384 "descriptors except for those that are ready for reading."
385 msgstr ""
386 "Po powrocie B<select>(), I<readfds> zostanie wyczyszczone ze wszystkich "
387 "deskryptorów pliku, poza gotowymi do odczytu."
388
389 #. type: TP
390 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
391 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
392 #, no-wrap
393 msgid "I<writefds>"
394 msgstr "I<writefds>"
395
396 #. type: Plain text
397 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
398 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
399 msgid ""
400 "The file descriptors in this set are watched to see if they are ready for "
401 "writing. A file descriptor is ready for writing if a write operation will "
402 "not block. However, even if a file descriptor indicates as writable, a "
403 "large write may still block."
404 msgstr ""
405 "Deskryptory pliku w tym zbiorze są monitorowane, aby sprawdzić, czy są "
406 "gotowe do zapisu. Deskryptor pliku jest gotowy do zapisu, jeśli wszystkie "
407 "operacje zapisu nie będą blokowały. Jednak nawet gdy deskryptor pliku jest "
408 "wskazywany jako zapisywalny, duży zapis może wciąż blokować."
409
410 #. type: Plain text
411 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
412 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
413 msgid ""
414 "After B<select>() has returned, I<writefds> will be cleared of all file "
415 "descriptors except for those that are ready for writing."
416 msgstr ""
417 "Po powrocie B<select>(), I<writefds> zostanie wyczyszczone ze wszystkich "
418 "deskryptorów pliku, poza gotowymi do zapisu."
419
420 #. type: TP
421 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
422 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
423 #, no-wrap
424 msgid "I<exceptfds>"
425 msgstr "I<exceptfds>"
426
427 #. type: Plain text
428 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
429 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
430 msgid ""
431 "The file descriptors in this set are watched for \"exceptional "
432 "conditions\". For examples of some exceptional conditions, see the "
433 "discussion of B<POLLPRI> in B<poll>(2)."
434 msgstr ""
435 "Deskryptory pliku w tym zbiorze są monitorowane pod kątem \\[Bq]szczególnych "
436 "okoliczności\\[rq]. Przykłady takich szczególnych okoliczności opisano w "
437 "podręczniku B<poll>(2) odnośnie B<POLLPRI>."
438
439 #. type: Plain text
440 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
441 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
442 msgid ""
443 "After B<select>() has returned, I<exceptfds> will be cleared of all file "
444 "descriptors except for those for which an exceptional condition has occurred."
445 msgstr ""
446 "Po powrocie B<select>(), I<exceptfds> zostanie wyczyszczone ze wszystkich "
447 "deskryptorów pliku, poza tymi, dla których zaszły szczególne okoliczności."
448
449 #. type: TP
450 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
451 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
452 #, no-wrap
453 msgid "I<nfds>"
454 msgstr "I<nfds>"
455
456 #. type: Plain text
457 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
458 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
459 msgid ""
460 "This argument should be set to the highest-numbered file descriptor in any "
461 "of the three sets, plus 1. The indicated file descriptors in each set are "
462 "checked, up to this limit (but see BUGS)."
463 msgstr ""
464 "Argument ten powinien być ustawiony na najwyższy numer deskryptora z "
465 "wszystkich trzech zbiorów plus 1. Sprawdzany jest wskazany deskryptor pliku "
466 "w każdym zbiorze, do tego limitu (lecz zob. USTERKI)."
467
468 #. type: TP
469 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
470 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
471 #, no-wrap
472 msgid "I<timeout>"
473 msgstr "I<timeout>"
474
475 #. type: Plain text
476 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
477 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
478 msgid ""
479 "The I<timeout> argument is a I<timeval> structure (shown below) that "
480 "specifies the interval that B<select>() should block waiting for a file "
481 "descriptor to become ready. The call will block until either:"
482 msgstr ""
483 "Argument I<timeout> jest strukturą I<timeval> (pokazaną niżej), określającą "
484 "interwał, który powinien blokować B<select>(), czekając na gotowość "
485 "deskryptora plików. Wywołanie będzie skutkowało blokadą do momentu aż:"
486
487 #. type: IP
488 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
489 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
490 #, no-wrap
491 msgid "\\[bu]"
492 msgstr "\\[bu]"
493
494 #. type: Plain text
495 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
496 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
497 msgid "a file descriptor becomes ready;"
498 msgstr "deskryptor pliku stanie się dostępny"
499
500 #. type: Plain text
501 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
502 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
503 msgid "the call is interrupted by a signal handler; or"
504 msgstr "lub wywołanie zostanie przerwane procedurą obsługi sygnału"
505
506 #. type: Plain text
507 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
508 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
509 msgid "the timeout expires."
510 msgstr "albo wywołanie przeterminuje się"
511
512 #. type: Plain text
513 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
514 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
515 msgid ""
516 "Note that the I<timeout> interval will be rounded up to the system clock "
517 "granularity, and kernel scheduling delays mean that the blocking interval "
518 "may overrun by a small amount."
519 msgstr ""
520 "Proszę zauważyć, że interwał zostanie zaokrąglony w górę do dokładności "
521 "zegara, a występowanie opóźnienia planisty jądra oznacza, że ten interwał "
522 "może być nieznacznie przekroczony."
523
524 #. type: Plain text
525 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
526 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
527 msgid ""
528 "If both fields of the I<timeval> structure are zero, then B<select>() "
529 "returns immediately. (This is useful for polling.)"
530 msgstr ""
531 "Jeśli oba pola struktury I<timeval> mają wartość zero, B<select>() "
532 "niezwłocznie zakończy pracę (jest to przydatne przy odpytywaniu)."
533
534 #. type: Plain text
535 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
536 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
537 msgid ""
538 "If I<timeout> is specified as NULL, B<select>() blocks indefinitely waiting "
539 "for a file descriptor to become ready."
540 msgstr ""
541 "Jeśli I<timeout> jest równe NULL, B<select>() może blokować w "
542 "nieskończoność, czekając na gotowość deskryptora pliku."
543
544 #. type: SS
545 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
546 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
547 #, no-wrap
548 msgid "pselect()"
549 msgstr "pselect()"
550
551 #. type: Plain text
552 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
553 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
554 msgid ""
555 "The B<pselect>() system call allows an application to safely wait until "
556 "either a file descriptor becomes ready or until a signal is caught."
557 msgstr ""
558 "Wywołanie systemowe B<pselect>() pozwala aplikacjom na bezpieczne "
559 "oczekiwanie, do momentu uzyskania gotowości przez deskryptor plików lub do "
560 "momentu przechwycenia sygnału."
561
562 #. type: Plain text
563 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
564 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
565 msgid ""
566 "The operation of B<select>() and B<pselect>() is identical, other than "
567 "these three differences:"
568 msgstr ""
569 "Funkcjonalność funkcji B<select>() i B<pselect>() jest identyczna, jeśli "
570 "pominąć trzy różnice:"
571
572 #. type: Plain text
573 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
574 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
575 msgid ""
576 "B<select>() uses a timeout that is a I<struct timeval> (with seconds and "
577 "microseconds), while B<pselect>() uses a I<struct timespec> (with seconds "
578 "and nanoseconds)."
579 msgstr ""
580 "Funkcja B<select>() używa dla parametru I<timeout> typu I<struct timeval> (z "
581 "sekundami i mikrosekundami), podczas gdy B<pselect>() używa typu I<struct "
582 "timespec> (z sekundami i nanosekundami)."
583
584 #. type: Plain text
585 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
586 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
587 msgid ""
588 "B<select>() may update the I<timeout> argument to indicate how much time "
589 "was left. B<pselect>() does not change this argument."
590 msgstr ""
591 "Funkcja B<select>() może aktualizować parametr I<timeout>, aby wskazać, jak "
592 "dużo czasu minęło. Funkcja B<pselect>() nie zmienia tego parametru."
593
594 #. type: Plain text
595 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
596 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
597 msgid ""
598 "B<select>() has no I<sigmask> argument, and behaves as B<pselect>() called "
599 "with NULL I<sigmask>."
600 msgstr ""
601 "Funkcja B<select>() nie przyjmuje parametru I<sigmask> i zachowuje się, jak "
602 "B<pselect>() wywołane z NULL-em przekazanym w I<sigmask>."
603
604 #. type: Plain text
605 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
606 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
607 msgid ""
608 "I<sigmask> is a pointer to a signal mask (see B<sigprocmask>(2)); if it is "
609 "not NULL, then B<pselect>() first replaces the current signal mask by the "
610 "one pointed to by I<sigmask>, then does the \"select\" function, and then "
611 "restores the original signal mask. (If I<sigmask> is NULL, the signal mask "
612 "is not modified during the B<pselect>() call.)"
613 msgstr ""
614 "I<sigmask> jest wskaźnikiem do maski sygnałów (zobacz B<sigprocmask>(2)). "
615 "Jeśli nie jest równe NULL, to B<pselect>() najpierw zastępuje bieżącą maskę "
616 "sygnałów maską wskazywaną przez I<sigmask>, a następnie wywołuje funkcję \\"
617 "[Bq]select\\[rq], a po jej zakończeniu odtwarza oryginalną maskę sygnałów "
618 "(jeśli I<sigmask> wynosi NULL, to maska sygnałów nie jest modyfikowana "
619 "podczas wywołania B<pselect>())."
620
621 #. type: Plain text
622 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
623 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
624 msgid ""
625 "Other than the difference in the precision of the I<timeout> argument, the "
626 "following B<pselect>() call:"
627 msgstr ""
628 "Poza różnicą w precyzji argumentu I<timeout>, następujące wywołanie "
629 "B<pselect>():"
630
631 #. type: Plain text
632 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
633 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
634 #, no-wrap
635 msgid ""
636 "ready = pselect(nfds, &readfds, &writefds, &exceptfds,\n"
637 " timeout, &sigmask);\n"
638 msgstr ""
639 "ready = pselect(nfds, &readfds, &writefds, &exceptfds,\n"
640 " timeout, &sigmask);\n"
641
642 #. type: Plain text
643 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
644 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
645 msgid "is equivalent to I<atomically> executing the following calls:"
646 msgstr "jest odpowiednikiem I<niepodzielnego> wykonania następujących funkcji:"
647
648 #. type: Plain text
649 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
650 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
651 #, no-wrap
652 msgid ""
653 "sigset_t origmask;\n"
654 "\\&\n"
655 "pthread_sigmask(SIG_SETMASK, &sigmask, &origmask);\n"
656 "ready = select(nfds, &readfds, &writefds, &exceptfds, timeout);\n"
657 "pthread_sigmask(SIG_SETMASK, &origmask, NULL);\n"
658 msgstr ""
659 "sigset_t origmask;\n"
660 "\\&\n"
661 "pthread_sigmask(SIG_SETMASK, &sigmask, &origmask);\n"
662 "ready = select(nfds, &readfds, &writefds, &exceptfds, timeout);\n"
663 "pthread_sigmask(SIG_SETMASK, &origmask, NULL);\n"
664
665 #. type: Plain text
666 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
667 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
668 msgid ""
669 "The reason that B<pselect>() is needed is that if one wants to wait for "
670 "either a signal or for a file descriptor to become ready, then an atomic "
671 "test is needed to prevent race conditions. (Suppose the signal handler sets "
672 "a global flag and returns. Then a test of this global flag followed by a "
673 "call of B<select>() could hang indefinitely if the signal arrived just "
674 "after the test but just before the call. By contrast, B<pselect>() allows "
675 "one to first block signals, handle the signals that have come in, then call "
676 "B<pselect>() with the desired I<sigmask>, avoiding the race.)"
677 msgstr ""
678 "Idea B<pselect>() polega na tym, że gdy chce się oczekiwać na zdarzenie "
679 "będące sygnałem lub czymś na deskryptorze pliku, potrzebny jest atomowy test "
680 "zapobiegający sytuacjom wyścigu. (Przypuśćmy, że procedura obsługi sygnału "
681 "ustawia globalny znacznik i kończy działanie. Wówczas, test tego znacznika "
682 "globalnego, po którym następuje wywołanie B<select>() może wisieć w "
683 "nieskończoność, gdyby sygnał przybył natychmiast po teście, ale przed "
684 "wywołaniem. Inaczej mówiąc, B<pselect> zezwala na, najpierw, zablokowanie "
685 "sygnałów, następnie obsłużenie dostarczonych sygnałów, aby wreszcie wywołać "
686 "B<pselect>() z pożądanym I<sigmask>, unikając wyścigu)."
687
688 #. type: SS
689 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
690 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
691 #, no-wrap
692 msgid "The timeout"
693 msgstr "Przeterminowanie"
694
695 #. type: Plain text
696 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
697 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
698 msgid ""
699 "The I<timeout> argument for B<select>() is a structure of the following "
700 "type:"
701 msgstr "Argument I<timeout> do B<select>() jest strukturą następującego typu:"
702
703 #. type: Plain text
704 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
705 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
706 #, no-wrap
707 msgid ""
708 "struct timeval {\n"
709 " time_t tv_sec; /* seconds */\n"
710 " suseconds_t tv_usec; /* microseconds */\n"
711 "};\n"
712 msgstr ""
713 "struct timeval {\n"
714 " time_t tv_sec; /* sekundy */\n"
715 " suseconds_t tv_usec; /* mikrosekundy */\n"
716 "};\n"
717
718 #. type: Plain text
719 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
720 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
721 msgid ""
722 "The corresponding argument for B<pselect>() is a B<timespec>(3) structure."
723 msgstr "Odpowiadającym argumentem B<pselect>() jest struktura B<timespec>(3)."
724
725 #. .P - it is rumored that:
726 #. On BSD, when a timeout occurs, the file descriptor bits are not changed.
727 #. - it is certainly true that:
728 #. Linux follows SUSv2 and sets the bit masks to zero upon a timeout.
729 #. type: Plain text
730 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
731 #: opensuse-tumbleweed
732 msgid ""
733 "On Linux, B<select>() modifies I<timeout> to reflect the amount of time not "
734 "slept; most other implementations do not do this. (POSIX.1 permits either "
735 "behavior.) This causes problems both when Linux code which reads I<timeout> "
736 "is ported to other operating systems, and when code is ported to Linux that "
737 "reuses a I<struct\\ timeval> for multiple B<select>()s in a loop without "
738 "reinitializing it. Consider I<timeout> to be undefined after B<select>() "
739 "returns."
740 msgstr ""
741 "Pod Linuksem funkcja B<select>() modyfikuje I<timeout>, aby odzwierciedlić "
742 "ilość nieprzespanego czasu; większość innych implementacji tego nie robi "
743 "(POSIX.1 dopuszcza oba te zachowania). Powoduje to problemy, zarówno gdy kod "
744 "linuksowy odczytujący I<timeout> zostanie przeniesiony na inne systemy "
745 "operacyjne, jak i gdy kod przeniesiony pod Linuksa z innych systemów używa "
746 "ponownie I<struct\\ timeval> dla wielu wywołań B<select>() w pętli, bez "
747 "powtórnej inicjacji. Prosimy rozważyć traktowanie wartości I<timeout> jako "
748 "niezdefiniowanej po zakończeniu funkcji B<select>()."
749
750 #. type: SH
751 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
752 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
753 #, no-wrap
754 msgid "RETURN VALUE"
755 msgstr "WARTOŚĆ ZWRACANA"
756
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 "On success, B<select>() and B<pselect>() return the number of file "
762 "descriptors contained in the three returned descriptor sets (that is, the "
763 "total number of bits that are set in I<readfds>, I<writefds>, "
764 "I<exceptfds>). The return value may be zero if the timeout expired before "
765 "any file descriptors became ready."
766 msgstr ""
767 "Po pomyślnym zakończeniu, B<select>() i B<pselect>() zwracają liczbę "
768 "deskryptorów w zbiorach deskryptorów (to jest całkowitą liczbę bitów "
769 "ustawioną w I<readfds>, I<writefds>, I<exceptfds>). Wartość zwracana może "
770 "wynosić zero, jeśli czas oczekiwania upłynął zanim jakiś deskryptor plików "
771 "stał się gotowy."
772
773 #. type: Plain text
774 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
775 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
776 msgid ""
777 "On error, -1 is returned, and I<errno> is set to indicate the error; the "
778 "file descriptor sets are unmodified, and I<timeout> becomes undefined."
779 msgstr ""
780 "Po błędzie zwracane jest -1 i ustawiane I<errno>, wskazując błąd; zbiory "
781 "deskryptorów nie są modyfikowane, a I<timeout> staje się niezdefiniowane."
782
783 #. type: SH
784 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
785 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
786 #, no-wrap
787 msgid "ERRORS"
788 msgstr "BŁĘDY"
789
790 #. type: TP
791 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
792 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
793 #, no-wrap
794 msgid "B<EBADF>"
795 msgstr "B<EBADF>"
796
797 #. type: Plain text
798 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
799 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
800 msgid ""
801 "An invalid file descriptor was given in one of the sets. (Perhaps a file "
802 "descriptor that was already closed, or one on which an error has occurred.) "
803 "However, see BUGS."
804 msgstr ""
805 "W jednym ze zbiorów przekazano niepoprawny deskryptor pliku (być może "
806 "deskryptor ten został już zamknięty lub wystąpił na nim inny błąd). Zob. "
807 "jednak BŁĘDY."
808
809 #. type: TP
810 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
811 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
812 #, no-wrap
813 msgid "B<EINTR>"
814 msgstr "B<EINTR>"
815
816 #. type: Plain text
817 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
818 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
819 msgid "A signal was caught; see B<signal>(7)."
820 msgstr "Przechwycono sygnał, patrz B<signal>(7)."
821
822 #. type: TP
823 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
824 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
825 #, no-wrap
826 msgid "B<EINVAL>"
827 msgstr "B<EINVAL>"
828
829 #. type: Plain text
830 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
831 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
832 msgid ""
833 "I<nfds> is negative or exceeds the B<RLIMIT_NOFILE> resource limit (see "
834 "B<getrlimit>(2))."
835 msgstr ""
836 "I<nfds> jest ujemne lub przekracza limit zasobów B<RLIMIT_NOFILE> (zob. "
837 "B<getrlimit>(2))."
838
839 #. type: Plain text
840 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
841 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
842 msgid "The value contained within I<timeout> is invalid."
843 msgstr "Wartość I<timeout> jest nieprawidłowa."
844
845 #. type: TP
846 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
847 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
848 #, no-wrap
849 msgid "B<ENOMEM>"
850 msgstr "B<ENOMEM>"
851
852 #. type: Plain text
853 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
854 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
855 msgid "Unable to allocate memory for internal tables."
856 msgstr "Nie można było przydzielić pamięci dla wewnętrznych tablic."
857
858 #. type: SH
859 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
860 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
861 #, no-wrap
862 msgid "VERSIONS"
863 msgstr "WERSJE"
864
865 #. Darwin, according to a report by Jeremy Sequoia, relayed by Josh Triplett
866 #. type: Plain text
867 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
868 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
869 msgid ""
870 "On some other UNIX systems, B<select>() can fail with the error B<EAGAIN> "
871 "if the system fails to allocate kernel-internal resources, rather than "
872 "B<ENOMEM> as Linux does. POSIX specifies this error for B<poll>(2), but not "
873 "for B<select>(). Portable programs may wish to check for B<EAGAIN> and "
874 "loop, just as with B<EINTR>."
875 msgstr ""
876 "Na niektórych innych systemach Uniksowych B<select>() może zwrócić błąd "
877 "B<EAGAIN> jeśli systemowi nie uda się przydzielić wewnątrzjądrowych zasobów, "
878 "zamiast B<ENOMEM>, tak jak robi to Linux. POSIX przewiduje ten błąd dla "
879 "B<poll>(2), lecz nie dla B<select>(). Przenośne programy mogą chcieć "
880 "sprawdzać B<EAGAIN> w pętli, tak jak dla B<EINTR>."
881
882 #. type: SH
883 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
884 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
885 #, no-wrap
886 msgid "STANDARDS"
887 msgstr "STANDARDY"
888
889 #. type: Plain text
890 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
891 #: opensuse-tumbleweed
892 msgid "POSIX.1-2024."
893 msgstr "POSIX.1-2024."
894
895 #. type: SH
896 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
897 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
898 #, no-wrap
899 msgid "HISTORY"
900 msgstr "HISTORIA"
901
902 #. type: TP
903 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
904 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
905 #, no-wrap
906 msgid "B<select>()"
907 msgstr "B<select>()"
908
909 #. type: Plain text
910 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
911 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
912 msgid "POSIX.1-2001, 4.4BSD (first appeared in 4.2BSD)."
913 msgstr "POSIX.1-2001, 4.4BSD (pojawiło się pierwotnie w 4.2BSD)."
914
915 #. type: Plain text
916 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
917 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
918 msgid ""
919 "Generally portable to/from non-BSD systems supporting clones of the BSD "
920 "socket layer (including System\\ V variants). However, note that the "
921 "System\\ V variant typically sets the timeout variable before returning, but "
922 "the BSD variant does not."
923 msgstr ""
924 "W ogólności jest przenośne do/z systemów nie-BSD wspierających sklonowaną "
925 "warstwę gniazd BSD (włączając warianty Systemu\\ V). Jednakże należy "
926 "zauważyć, że warianty Systemu\\ V zasadniczo ustawiają zmienną "
927 "przeterminowania przed powrotem, ale wariant BSD tego nie robi."
928
929 #. type: TP
930 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
931 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
932 #, no-wrap
933 msgid "B<pselect>()"
934 msgstr "B<pselect>()"
935
936 #. type: Plain text
937 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
938 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
939 msgid "Linux 2.6.16. POSIX.1g, POSIX.1-2001."
940 msgstr "Linux 2.6.16. POSIX.1g, POSIX.1-2001."
941
942 #. type: Plain text
943 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
944 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
945 msgid "Prior to this, it was emulated in glibc (but see BUGS)."
946 msgstr "Wcześniej był on emulowany w glibc (patrz również USTERKI)."
947
948 #. type: TP
949 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
950 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
951 #, no-wrap
952 msgid "B<fd_set>"
953 msgstr "B<fd_set>"
954
955 #. type: Plain text
956 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
957 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
958 msgid "POSIX.1-2001."
959 msgstr "POSIX.1-2001."
960
961 #. type: SH
962 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
963 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
964 #, no-wrap
965 msgid "NOTES"
966 msgstr "UWAGI"
967
968 #. type: Plain text
969 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
970 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
971 msgid ""
972 "The following header also provides the I<fd_set> type: I<E<lt>sys/"
973 "time.hE<gt>>."
974 msgstr ""
975 "Następujący nagłówek zapewnia również typ I<fd_set>: I<E<lt>sys/time.hE<gt>>."
976
977 #. type: Plain text
978 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
979 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
980 msgid ""
981 "An I<fd_set> is a fixed size buffer. Executing B<FD_CLR>() or B<FD_SET>() "
982 "with a value of I<fd> that is negative or is equal to or larger than "
983 "B<FD_SETSIZE> will result in undefined behavior. Moreover, POSIX requires "
984 "I<fd> to be a valid file descriptor."
985 msgstr ""
986 "I<fd_set> jest buforem o stałym rozmiarze. Wykonanie B<FD_CLR>() lub "
987 "B<FD_SET>() z ujemną wartością I<fd> albo z wartością większą lub równą "
988 "B<FD_SETSIZE> spowoduje zachowanie niezdefiniowane. Ponadto POSIX wymaga, by "
989 "I<fd> był prawidłowym deskryptorem pliku."
990
991 #. type: Plain text
992 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
993 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
994 msgid ""
995 "The operation of B<select>() and B<pselect>() is not affected by the "
996 "B<O_NONBLOCK> flag."
997 msgstr ""
998 "Na działanie B<select>() i B<pselect>() nie wpływa znacznik B<O_NONBLOCK>."
999
1000 #. type: SS
1001 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1002 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1003 #, no-wrap
1004 msgid "The self-pipe trick"
1005 msgstr "Sztuczka \\[Bq]potoku do siebie\\[rq]"
1006
1007 #. type: Plain text
1008 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1009 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1010 msgid ""
1011 "On systems that lack B<pselect>(), reliable (and more portable) signal "
1012 "trapping can be achieved using the self-pipe trick. In this technique, a "
1013 "signal handler writes a byte to a pipe whose other end is monitored by "
1014 "B<select>() in the main program. (To avoid possibly blocking when writing "
1015 "to a pipe that may be full or reading from a pipe that may be empty, "
1016 "nonblocking I/O is used when reading from and writing to the pipe.)"
1017 msgstr ""
1018 "W systemach, które nie mają B<pselect>() niezawodne (i bardziej przenośne) "
1019 "przechwytywanie sygnałów można osiągnąć, używając sztuczki w postaci \\"
1020 "[Bq]potoku do siebie\\[rq]. W tej technice procedura obsługi sygnału "
1021 "zapisuje bajt do potoku, którego drugi koniec jest monitorowany przez "
1022 "B<select>() w głównym programie. Aby uniknąć możliwego zablokowania przy "
1023 "pisaniu do potoku który może być pełny lub czytaniu z potoku który może być "
1024 "pusty, przy czytaniu z i pisaniu do potoku używane jest nieblokujące wejście/"
1025 "wyjście."
1026
1027 #. type: SS
1028 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1029 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1030 #, no-wrap
1031 msgid "Emulating usleep(3)"
1032 msgstr "Emulowanie usleep(3)"
1033
1034 #. type: Plain text
1035 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1036 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1037 msgid ""
1038 "Before the advent of B<usleep>(3), some code employed a call to B<select>() "
1039 "with all three sets empty, I<nfds> zero, and a non-NULL I<timeout> as a "
1040 "fairly portable way to sleep with subsecond precision."
1041 msgstr ""
1042 "Przed powstaniem B<usleep>(3) niektóre programy używały wywołania "
1043 "B<select>() z wszystkimi trzema zbiorami pustymi, z I<nfds> równym zeru i "
1044 "niezerowym I<timeout>. Jest to całkiem przenośny sposób pauzowania z "
1045 "dokładnością subsekundową."
1046
1047 #. type: SS
1048 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1049 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1050 #, no-wrap
1051 msgid "Correspondence between select() and poll() notifications"
1052 msgstr "Relacja pomiędzy powiadomieniami select() i poll()"
1053
1054 #. fs/select.c
1055 #. type: Plain text
1056 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1057 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1058 msgid ""
1059 "Within the Linux kernel source, we find the following definitions which show "
1060 "the correspondence between the readable, writable, and exceptional condition "
1061 "notifications of B<select>() and the event notifications provided by "
1062 "B<poll>(2) and B<epoll>(7):"
1063 msgstr ""
1064 "W źródłach jądra Linux można znaleźć następujące definicje pokazujące "
1065 "relację pomiędzy powiadomieniami o warunkach: odczytu, zapisu i szczególnych "
1066 "okoliczności B<select>(), a powiadomieniami zdarzeń zapewnianymi przez "
1067 "B<poll>(2) i B<epoll>(7):"
1068
1069 #. type: Plain text
1070 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1071 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1072 #, no-wrap
1073 msgid ""
1074 "#define POLLIN_SET (EPOLLRDNORM | EPOLLRDBAND | EPOLLIN |\n"
1075 " EPOLLHUP | EPOLLERR)\n"
1076 " /* Ready for reading */\n"
1077 "#define POLLOUT_SET (EPOLLWRBAND | EPOLLWRNORM | EPOLLOUT |\n"
1078 " EPOLLERR)\n"
1079 " /* Ready for writing */\n"
1080 "#define POLLEX_SET (EPOLLPRI)\n"
1081 " /* Exceptional condition */\n"
1082 msgstr ""
1083 "#define POLLIN_SET (EPOLLRDNORM | EPOLLRDBAND | EPOLLIN |\n"
1084 " EPOLLHUP | EPOLLERR)\n"
1085 " /* Gotowość do odczytu */\n"
1086 "#define POLLOUT_SET (EPOLLWRBAND | EPOLLWRNORM | EPOLLOUT |\n"
1087 " EPOLLERR)\n"
1088 " /* Gotowość do zapisu */\n"
1089 "#define POLLEX_SET (EPOLLPRI)\n"
1090 " /* Szczególne okoliczności */\n"
1091
1092 #. type: SS
1093 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1094 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1095 #, no-wrap
1096 msgid "Multithreaded applications"
1097 msgstr "Aplikacje wielowątkowe"
1098
1099 #. type: Plain text
1100 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1101 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1102 msgid ""
1103 "If a file descriptor being monitored by B<select>() is closed in another "
1104 "thread, the result is unspecified. On some UNIX systems, B<select>() "
1105 "unblocks and returns, with an indication that the file descriptor is ready "
1106 "(a subsequent I/O operation will likely fail with an error, unless another "
1107 "process reopens the file descriptor between the time B<select>() returned "
1108 "and the I/O operation is performed). On Linux (and some other systems), "
1109 "closing the file descriptor in another thread has no effect on B<select>(). "
1110 "In summary, any application that relies on a particular behavior in this "
1111 "scenario must be considered buggy."
1112 msgstr ""
1113 "Jeśli deskryptor plików monitorowany przez B<select>() zostanie zamknięty w "
1114 "innym wątku, to rezultat jest nieokreślony. Na niektórych systemach "
1115 "uniksowych B<select>() odblokuje go i powróci wskazując, że dany deskryptor "
1116 "plików jest gotowy (kolejne operacje wyjścia/wyjścia prawdopodobnie zakończą "
1117 "się błędem, chyba że inny proces otworzy ponownie deskryptor plików w czasie "
1118 "pomiędzy powrotem B<select>() a wykonanie operacji wejścia/wyjścia. W "
1119 "systemie Linux (i części innych) zamknięcie deskryptora pliku w innym wątku "
1120 "nie wpłynie na B<select>(). Podsumowując, każda aplikacja polegająca na "
1121 "konkretnym zachowaniu w takim przypadku musi być uznana za błędną."
1122
1123 #. type: SS
1124 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1125 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1126 #, no-wrap
1127 msgid "C library/kernel differences"
1128 msgstr "Różnice biblioteki C/jądra"
1129
1130 #. type: Plain text
1131 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1132 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1133 msgid ""
1134 "The Linux kernel allows file descriptor sets of arbitrary size, determining "
1135 "the length of the sets to be checked from the value of I<nfds>. However, in "
1136 "the glibc implementation, the I<fd_set> type is fixed in size. See also "
1137 "BUGS."
1138 msgstr ""
1139 "Jądro Linux pozwala deskryptorowi pliku ustawić dowolny rozmiar, na "
1140 "podstawie długości zbiorów do sprawdzenia z wartości I<nfds>. Jednak w "
1141 "implementacji glibc, typ I<fd_set> ma stały rozmiar. Zob. też USTERKI."
1142
1143 #. type: Plain text
1144 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1145 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1146 msgid ""
1147 "The B<pselect>() interface described in this page is implemented by glibc. "
1148 "The underlying Linux system call is named B<pselect6>(). This system call "
1149 "has somewhat different behavior from the glibc wrapper function."
1150 msgstr ""
1151 "Interfejs B<pselect>() opisany w niniejszym podręczniku jest "
1152 "zaimplementowany w glibc. Stojące za nim linuksowe wywołanie systemowe "
1153 "nazywa się B<pselect6>(). Cechuje go nieco inne zachowanie od opisywanej "
1154 "funkcji opakowującej glibc."
1155
1156 #. type: Plain text
1157 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1158 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1159 msgid ""
1160 "The Linux B<pselect6>() system call modifies its I<timeout> argument. "
1161 "However, the glibc wrapper function hides this behavior by using a local "
1162 "variable for the timeout argument that is passed to the system call. Thus, "
1163 "the glibc B<pselect>() function does not modify its I<timeout> argument; "
1164 "this is the behavior required by POSIX.1-2001."
1165 msgstr ""
1166 "Wywołanie systemowe B<pselect6>() pod Linuksem modyfikuje argument "
1167 "I<timeout>. Jednakże funkcja glibc ukrywa to zachowanie przez użycie dla "
1168 "argumentu timeout lokalnej zmiennej, która jest przekazywana do wywołania "
1169 "systemowego. Dlatego B<pselect>() z glibc nie zmienia argumentu I<timeout>, "
1170 "co jest zachowaniem wymaganym przez POSIX.1-2001."
1171
1172 #. type: Plain text
1173 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1174 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1175 msgid ""
1176 "The final argument of the B<pselect6>() system call is not a I<sigset_t\\ "
1177 "*> pointer, but is instead a structure of the form:"
1178 msgstr ""
1179 "Ostatnim argumentem wywołania systemowego B<pselect6>() nie jest wskaźnik "
1180 "I<sigset_t\\ *> lecz struktura postaci:"
1181
1182 #. type: Plain text
1183 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1184 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1185 #, no-wrap
1186 msgid ""
1187 "struct {\n"
1188 " const kernel_sigset_t *ss; /* Pointer to signal set */\n"
1189 " size_t ss_len; /* Size (in bytes) of object\n"
1190 " pointed to by \\[aq]ss\\[aq] */\n"
1191 "};\n"
1192 msgstr ""
1193 "struct {\n"
1194 " const kernel_sigset_t *ss; /* Wskaźnik do zestawu sygnałów */\n"
1195 " size_t ss_len; /* Rozmiar (w bajtach) obiektu, na\n"
1196 " który wskazuje \\[aq]ss\\[aq] */\n"
1197 "};\n"
1198
1199 #. type: Plain text
1200 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1201 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1202 msgid ""
1203 "This allows the system call to obtain both a pointer to the signal set and "
1204 "its size, while allowing for the fact that most architectures support a "
1205 "maximum of 6 arguments to a system call. See B<sigprocmask>(2) for a "
1206 "discussion of the difference between the kernel and libc notion of the "
1207 "signal set."
1208 msgstr ""
1209 "Pozwala to wywołaniu systemowemu pobrać oba wskaźniki do zestawu sygnałowego "
1210 "wraz z rozmiarem, biorąc pod uwagę, że większość architektur obsługuje "
1211 "maksymalnie 6 argumentów do wywołania systemowego. Opis różnic pomiędzy "
1212 "podejściem jądra i libc do zestawu sygnałów znajduje się w podręczniku "
1213 "B<sigprocmask>(2)."
1214
1215 #. type: SS
1216 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1217 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1218 #, no-wrap
1219 msgid "Historical glibc details"
1220 msgstr "Historyczne detale glibc"
1221
1222 #. type: Plain text
1223 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1224 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1225 msgid ""
1226 "glibc 2.0 provided an incorrect version of B<pselect>() that did not take a "
1227 "I<sigmask> argument."
1228 msgstr ""
1229 "glibc 2.0 dostarczała niepoprawną wersję B<pselect>(), która nie przyjmowała "
1230 "argumentu I<sigmask>."
1231
1232 #. type: Plain text
1233 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1234 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1235 msgid ""
1236 "From glibc 2.1 to glibc 2.2.1, one must define B<_GNU_SOURCE> in order to "
1237 "obtain the declaration of B<pselect>() from I<E<lt>sys/select.hE<gt>>."
1238 msgstr ""
1239 "Od glibc 2.1 do glibc 2.2.1 konieczne było zdefiniowanie B<_GNU_SOURCE>, aby "
1240 "uzyskać deklarację B<pselect>() z I<E<lt>sys/select.hE<gt>>."
1241
1242 #. type: SH
1243 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1244 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1245 #, no-wrap
1246 msgid "BUGS"
1247 msgstr "USTERKI"
1248
1249 #. type: Plain text
1250 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1251 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1252 msgid ""
1253 "POSIX allows an implementation to define an upper limit, advertised via the "
1254 "constant B<FD_SETSIZE>, on the range of file descriptors that can be "
1255 "specified in a file descriptor set. The Linux kernel imposes no fixed "
1256 "limit, but the glibc implementation makes I<fd_set> a fixed-size type, with "
1257 "B<FD_SETSIZE> defined as 1024, and the B<FD_*>() macros operating according "
1258 "to that limit. To monitor file descriptors greater than 1023, use "
1259 "B<poll>(2) or B<epoll>(7) instead."
1260 msgstr ""
1261 "POSIX pozwala implementacji zdefiniować górny limit zakresu deskryptorów "
1262 "plików, które można podać w zbiorze deskryptora pliku, rozgłaszany stałą "
1263 "B<FD_SETSIZE>. Jądro Linux nie wymusza stałego limitu, lecz implementacja "
1264 "glibc czyni I<fd_set> typem o stałym rozmiarze, z B<FD_SETSIZE> "
1265 "zdefiniowanym jako 1024 i makrami B<FD_*>() działającymi zgodnie z tym "
1266 "limitem. Aby monitorować deskryptory plików większe niż 1023, należy w "
1267 "zamian użyć B<poll>(2) lub B<epoll>(7)."
1268
1269 #. type: Plain text
1270 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1271 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1272 msgid ""
1273 "The implementation of the I<fd_set> arguments as value-result arguments is a "
1274 "design error that is avoided in B<poll>(2) and B<epoll>(7)."
1275 msgstr ""
1276 "Implementacja argumentów I<fd_set> jako argumentów wartość-wynik jest błędem "
1277 "projektowym, którego uniknięto w B<poll>(2) i B<epoll>(7)."
1278
1279 #. type: Plain text
1280 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1281 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1282 msgid ""
1283 "According to POSIX, B<select>() should check all specified file descriptors "
1284 "in the three file descriptor sets, up to the limit I<nfds-1>. However, the "
1285 "current implementation ignores any file descriptor in these sets that is "
1286 "greater than the maximum file descriptor number that the process currently "
1287 "has open. According to POSIX, any such file descriptor that is specified in "
1288 "one of the sets should result in the error B<EBADF>."
1289 msgstr ""
1290 "Zgodnie z POSIX, B<select>() powinien sprawdzać wszystkie podane deskryptory "
1291 "pliku w trzech zbiorach deskryptorów pliku, do limitu I<nfds-1>. Jednak "
1292 "bieżąca implementacja ignoruje wszelkie deskryptory pliku w tych zbiorach, "
1293 "które są wyższe od maksymalnego numeru aktualnie otwartego przez proces "
1294 "deskryptora pliku. Zgodnie z POSIX, w przypadku wystąpienia takiego "
1295 "deskryptora pliku w jednym z zbiorów, powinien wystąpić błąd B<EBADF>."
1296
1297 #. type: Plain text
1298 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1299 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1300 msgid ""
1301 "Starting with glibc 2.1, glibc provided an emulation of B<pselect>() that "
1302 "was implemented using B<sigprocmask>(2) and B<select>(). This "
1303 "implementation remained vulnerable to the very race condition that "
1304 "B<pselect>() was designed to prevent. Modern versions of glibc use the "
1305 "(race-free) B<pselect>() system call on kernels where it is provided."
1306 msgstr ""
1307 "Od glibc 2.1, glibc dostarczała emulację B<pselect>(), która była "
1308 "zaimplementowana przy użyciu B<sigprocmask>(2) i B<select>(). Implementacja "
1309 "ta pozostaje podatna na wiele błędów wyścigów (race conditions), których "
1310 "uniknięcie stanowiło ideę funkcji B<pselect>(). Nowsze wersje glibc używają "
1311 "(wolnego od wyścigów) wywołania systemowego, jeśli tylko jądro dostarcza "
1312 "takiego wywołania."
1313
1314 #. Stevens discusses a case where accept can block after select
1315 #. returns successfully because of an intervening RST from the client.
1316 #. Maybe the kernel should have returned EIO in such a situation?
1317 #. type: Plain text
1318 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1319 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1320 msgid ""
1321 "On Linux, B<select>() may report a socket file descriptor as \"ready for "
1322 "reading\", while nevertheless a subsequent read blocks. This could for "
1323 "example happen when data has arrived but upon examination has the wrong "
1324 "checksum and is discarded. There may be other circumstances in which a file "
1325 "descriptor is spuriously reported as ready. Thus it may be safer to use "
1326 "B<O_NONBLOCK> on sockets that should not block."
1327 msgstr ""
1328 "W Linuksie B<select>() może raportować deskryptory plików gniazd jako \\"
1329 "[Bq]dostępne do czytania\\[rq], podczas gdy kolejne czytania zostaną "
1330 "zablokowane. Może to się zdarzyć na przykład wtedy, gdy dane nadeszły, ale "
1331 "podczas sprawdzania okazało się, że mają złą sumę kontrolną i zostały "
1332 "odrzucone. Mogą wystąpić także inne sytuacje, w których deskryptor pliku "
1333 "jest błędnie raportowany jako gotowy. Dlatego używanie B<O_NONBLOCK> na "
1334 "gniazdach, które nie powinny się blokować może być bezpieczniejsze."
1335
1336 #. type: Plain text
1337 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1338 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1339 msgid ""
1340 "On Linux, B<select>() also modifies I<timeout> if the call is interrupted "
1341 "by a signal handler (i.e., the B<EINTR> error return). This is not "
1342 "permitted by POSIX.1. The Linux B<pselect>() system call has the same "
1343 "behavior, but the glibc wrapper hides this behavior by internally copying "
1344 "the I<timeout> to a local variable and passing that variable to the system "
1345 "call."
1346 msgstr ""
1347 "Pod Linuksem wywołanie B<select>() zmienia wartość I<timeout> także wtedy, "
1348 "gdy zostanie przerwane przez procedurę obsługi sygnału (tj. zostanie "
1349 "zwrócony błąd B<EINTR>). POSIX.1 nie pozwala na takie zachowanie. Wywołanie "
1350 "systemowe B<pselect>() pod Linuksem zachowuje się tak samo, ale funkcja "
1351 "opakowująca biblioteki glibc ukrywa to zachowanie, kopiując wartość "
1352 "I<timeout> do wewnętrznej lokalnej zmiennej i przekazując tę zmienną do "
1353 "wywołania systemowego."
1354
1355 #. type: SH
1356 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1357 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1358 #, no-wrap
1359 msgid "EXAMPLES"
1360 msgstr "PRZYKŁADY"
1361
1362 #. type: Plain text
1363 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
1364 #: opensuse-tumbleweed
1365 #, no-wrap
1366 msgid ""
1367 "#include E<lt>stdio.hE<gt>\n"
1368 "#include E<lt>stdlib.hE<gt>\n"
1369 "#include E<lt>sys/select.hE<gt>\n"
1370 "#include E<lt>sys/time.hE<gt>\n"
1371 "\\&\n"
1372 "int\n"
1373 "main(void)\n"
1374 "{\n"
1375 " int retval;\n"
1376 " fd_set rfds;\n"
1377 " struct timeval tv;\n"
1378 "\\&\n"
1379 " /* Watch stdin (fd 0) to see when it has input. */\n"
1380 "\\&\n"
1381 " FD_ZERO(&rfds);\n"
1382 " FD_SET(0, &rfds);\n"
1383 "\\&\n"
1384 " /* Wait up to five seconds. */\n"
1385 "\\&\n"
1386 " tv.tv_sec = 5;\n"
1387 " tv.tv_usec = 0;\n"
1388 "\\&\n"
1389 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1390 " /* Don\\[aq]t rely on the value of tv now! */\n"
1391 "\\&\n"
1392 " if (retval == -1)\n"
1393 " perror(\"select()\");\n"
1394 " else if (retval)\n"
1395 " printf(\"Data is available now.\\[rs]n\");\n"
1396 " /* FD_ISSET(0, &rfds) will be true. */\n"
1397 " else\n"
1398 " printf(\"No data within five seconds.\\[rs]n\");\n"
1399 "\\&\n"
1400 " exit(EXIT_SUCCESS);\n"
1401 "}\n"
1402 msgstr ""
1403 "#include E<lt>stdio.hE<gt>\n"
1404 "#include E<lt>stdlib.hE<gt>\n"
1405 "#include E<lt>sys/select.hE<gt>\n"
1406 "#include E<lt>sys/time.hE<gt>\n"
1407 "\\&\n"
1408 "int\n"
1409 "main(void)\n"
1410 "{\n"
1411 " int retval;\n"
1412 " fd_set rfds;\n"
1413 " struct timeval tv;\n"
1414 "\\&\n"
1415 " /* Obserwacja stdin (fd 0) i sprawdzanie kiedy ma wejście. */\n"
1416 "\\&\n"
1417 " FD_ZERO(&rfds);\n"
1418 " FD_SET(0, &rfds);\n"
1419 "\\&\n"
1420 " /* Czekanie do pięciu sekund. */\n"
1421 "\\&\n"
1422 " tv.tv_sec = 5;\n"
1423 " tv.tv_usec = 0;\n"
1424 "\\&\n"
1425 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1426 " /* Nie należy już polegać na wartości tv! */\n"
1427 "\\&\n"
1428 " if (retval == -1)\n"
1429 " perror(\"select()\");\n"
1430 " else if (retval)\n"
1431 " printf(\"Dane są już dostępne.\\[rs]n\");\n"
1432 " /* FD_ISSET(0, &rfds) będzie prawdziwy. */\n"
1433 " else\n"
1434 " printf(\"Brak danych w ciągu pięciu sekund.\\[rs]n\");\n"
1435 "\\&\n"
1436 " exit(EXIT_SUCCESS);\n"
1437 "}\n"
1438
1439 #. SRC END
1440 #. type: SH
1441 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1442 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1443 #, no-wrap
1444 msgid "SEE ALSO"
1445 msgstr "ZOBACZ TAKŻE"
1446
1447 #. type: Plain text
1448 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1449 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1450 msgid ""
1451 "B<accept>(2), B<connect>(2), B<poll>(2), B<read>(2), B<recv>(2), "
1452 "B<restart_syscall>(2), B<send>(2), B<sigprocmask>(2), B<write>(2), "
1453 "B<timespec>(3), B<epoll>(7), B<time>(7)"
1454 msgstr ""
1455 "B<accept>(2), B<connect>(2), B<poll>(2), B<read>(2), B<recv>(2), "
1456 "B<restart_syscall>(2), B<send>(2), B<sigprocmask>(2), B<write>(2), "
1457 "B<timespec>(3), B<epoll>(7), B<time>(7)"
1458
1459 #. type: Plain text
1460 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1461 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1462 msgid "For a tutorial with discussion and examples, see B<select_tut>(2)."
1463 msgstr "Samouczek z dyskusją i przykładami znajduje się w B<select_tut>(2)."
1464
1465 #. type: TH
1466 #: debian-trixie
1467 #, no-wrap
1468 msgid "2024-06-15"
1469 msgstr "15 czerwca 2024 r."
1470
1471 #. type: TH
1472 #: debian-trixie
1473 #, no-wrap
1474 msgid "Linux man-pages 6.9.1"
1475 msgstr "Linux man-pages 6.9.1"
1476
1477 #. type: Plain text
1478 #: debian-trixie
1479 msgid "Standard C library (I<libc>, I<-lc>)"
1480 msgstr "Standardowa biblioteka C (I<libc>, I<-lc>)"
1481
1482 #. type: Plain text
1483 #: debian-trixie fedora-44 fedora-rawhide
1484 #, no-wrap
1485 msgid "B<typedef> /* ... */ B<fd_set;>\n"
1486 msgstr "B<typedef> /* ... */ B<fd_set;>\n"
1487
1488 #. type: Plain text
1489 #: debian-trixie fedora-44 fedora-rawhide
1490 #, no-wrap
1491 msgid ""
1492 "B<void FD_CLR(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1493 "B<int FD_ISSET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1494 "B<void FD_SET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1495 "B<void FD_ZERO(fd_set *>I<set>B<);>\n"
1496 msgstr ""
1497 "B<void FD_CLR(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1498 "B<int FD_ISSET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1499 "B<void FD_SET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1500 "B<void FD_ZERO(fd_set *>I<set>B<);>\n"
1501
1502 #. .P - it is rumored that:
1503 #. On BSD, when a timeout occurs, the file descriptor bits are not changed.
1504 #. - it is certainly true that:
1505 #. Linux follows SUSv2 and sets the bit masks to zero upon a timeout.
1506 #. type: Plain text
1507 #: debian-trixie fedora-44 fedora-rawhide
1508 msgid ""
1509 "On Linux, B<select>() modifies I<timeout> to reflect the amount of time not "
1510 "slept; most other implementations do not do this. (POSIX.1 permits either "
1511 "behavior.) This causes problems both when Linux code which reads I<timeout> "
1512 "is ported to other operating systems, and when code is ported to Linux that "
1513 "reuses a I<struct timeval> for multiple B<select>()s in a loop without "
1514 "reinitializing it. Consider I<timeout> to be undefined after B<select>() "
1515 "returns."
1516 msgstr ""
1517 "Pod Linuksem funkcja B<select>() modyfikuje I<timeout>, aby odzwierciedlić "
1518 "ilość nieprzespanego czasu; większość innych implementacji tego nie robi "
1519 "(POSIX.1 dopuszcza oba te zachowania). Powoduje to problemy, zarówno gdy kod "
1520 "linuksowy odczytujący I<timeout> zostanie przeniesiony na inne systemy "
1521 "operacyjne, jak i gdy kod przeniesiony pod Linuksa z innych systemów używa "
1522 "ponownie struktury I<timeval> dla wielu wywołań B<select>() w pętli, bez "
1523 "powtórnej inicjacji. Prosimy rozważyć traktowanie wartości I<timeout> jako "
1524 "niezdefiniowanej po zakończeniu funkcji B<select>()."
1525
1526 #. type: Plain text
1527 #: debian-trixie fedora-44 fedora-rawhide
1528 msgid "POSIX.1-2008."
1529 msgstr "POSIX.1-2008."
1530
1531 #. type: Plain text
1532 #: debian-trixie
1533 #, no-wrap
1534 msgid ""
1535 "#include E<lt>stdio.hE<gt>\n"
1536 "#include E<lt>stdlib.hE<gt>\n"
1537 "#include E<lt>sys/select.hE<gt>\n"
1538 "\\&\n"
1539 "int\n"
1540 "main(void)\n"
1541 "{\n"
1542 " int retval;\n"
1543 " fd_set rfds;\n"
1544 " struct timeval tv;\n"
1545 "\\&\n"
1546 " /* Watch stdin (fd 0) to see when it has input. */\n"
1547 "\\&\n"
1548 " FD_ZERO(&rfds);\n"
1549 " FD_SET(0, &rfds);\n"
1550 "\\&\n"
1551 " /* Wait up to five seconds. */\n"
1552 "\\&\n"
1553 " tv.tv_sec = 5;\n"
1554 " tv.tv_usec = 0;\n"
1555 "\\&\n"
1556 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1557 " /* Don\\[aq]t rely on the value of tv now! */\n"
1558 "\\&\n"
1559 " if (retval == -1)\n"
1560 " perror(\"select()\");\n"
1561 " else if (retval)\n"
1562 " printf(\"Data is available now.\\[rs]n\");\n"
1563 " /* FD_ISSET(0, &rfds) will be true. */\n"
1564 " else\n"
1565 " printf(\"No data within five seconds.\\[rs]n\");\n"
1566 "\\&\n"
1567 " exit(EXIT_SUCCESS);\n"
1568 "}\n"
1569 msgstr ""
1570 "#include E<lt>stdio.hE<gt>\n"
1571 "#include E<lt>stdlib.hE<gt>\n"
1572 "#include E<lt>sys/select.hE<gt>\n"
1573 "\\&\n"
1574 "int\n"
1575 "main(void)\n"
1576 "{\n"
1577 " int retval;\n"
1578 " fd_set rfds;\n"
1579 " struct timeval tv;\n"
1580 "\\&\n"
1581 " /* Obserwacja stdin (fd 0) i sprawdzanie kiedy ma wejście. */\n"
1582 "\\&\n"
1583 " FD_ZERO(&rfds);\n"
1584 " FD_SET(0, &rfds);\n"
1585 "\\&\n"
1586 " /* Czekanie do pięciu sekund. */\n"
1587 "\\&\n"
1588 " tv.tv_sec = 5;\n"
1589 " tv.tv_usec = 0;\n"
1590 "\\&\n"
1591 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1592 " /* Nie należy już polegać na wartości tv! */\n"
1593 "\\&\n"
1594 " if (retval == -1)\n"
1595 " perror(\"select()\");\n"
1596 " else if (retval)\n"
1597 " printf(\"Dane są już dostępne.\\[rs]n\");\n"
1598 " /* FD_ISSET(0, &rfds) będzie prawdziwy. */\n"
1599 " else\n"
1600 " printf(\"Brak danych w ciągu pięciu sekund.\\[rs]n\");\n"
1601 "\\&\n"
1602 " exit(EXIT_SUCCESS);\n"
1603 "}\n"
1604
1605 #. type: TH
1606 #: fedora-44 fedora-rawhide
1607 #, no-wrap
1608 msgid "2024-11-03"
1609 msgstr "3 listopada 2024 r."
1610
1611 #. type: TH
1612 #: fedora-44 fedora-rawhide
1613 #, no-wrap
1614 msgid "Linux man-pages 6.13"
1615 msgstr "Linux man-pages 6.13"
1616
1617 #. type: Plain text
1618 #: fedora-44 fedora-rawhide
1619 #, no-wrap
1620 msgid ""
1621 "#include E<lt>stdio.hE<gt>\n"
1622 "#include E<lt>stdlib.hE<gt>\n"
1623 "#include E<lt>sys/select.hE<gt>\n"
1624 "#include E<lt>sys/time.hE<gt>\n"
1625 "\\&\n"
1626 "int\n"
1627 "main(void)\n"
1628 "{\n"
1629 " int retval;\n"
1630 " fd_set rfds;\n"
1631 " struct timeval tv;\n"
1632 "\\&\n"
1633 " /* Watch stdin (fd 0) to see when it has input. */\n"
1634 "\\&\n"
1635 " FD_ZERO(&rfds);\n"
1636 " FD_SET(0, &rfds);\n"
1637 "\\&\n"
1638 " /* Wait up to five seconds. */\n"
1639 "\\&\n"
1640 " tv.tv_sec = 5;\n"
1641 " tv.tv_usec = 0;\n"
1642 "\\&\n"
1643 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1644 " /* Don\\[aq]t rely on the value of tv now! */\n"
1645 "\\&\n"
1646 " if (retval == -1)\n"
1647 " perror(\"select()\");\n"
1648 " else if (retval)\n"
1649 " printf(\"Data is available now.\\[rs]n\");\n"
1650 " /* FD_ISSET(0, &rfds) will be true. */\n"
1651 " else\n"
1652 " printf(\"No data within five seconds.\\[rs]n\");\n"
1653 "\\&\n"
1654 " exit(EXIT_SUCCESS);\n"
1655 "}\n"
1656 msgstr ""
1657 "#include E<lt>stdio.hE<gt>\n"
1658 "#include E<lt>stdlib.hE<gt>\n"
1659 "#include E<lt>sys/select.hE<gt>\n"
1660 "#include E<lt>sys/time.hE<gt>\n"
1661 "\\&\n"
1662 "int\n"
1663 "main(void)\n"
1664 "{\n"
1665 " int retval;\n"
1666 " fd_set rfds;\n"
1667 " struct timeval tv;\n"
1668 "\\&\n"
1669 " /* Obserwacja stdin (fd 0) i sprawdzanie kiedy ma wejście. */\n"
1670 "\\&\n"
1671 " FD_ZERO(&rfds);\n"
1672 " FD_SET(0, &rfds);\n"
1673 "\\&\n"
1674 " /* Czekanie do pięciu sekund. */\n"
1675 "\\&\n"
1676 " tv.tv_sec = 5;\n"
1677 " tv.tv_usec = 0;\n"
1678 "\\&\n"
1679 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1680 " /* Nie należy już polegać na wartości tv! */\n"
1681 "\\&\n"
1682 " if (retval == -1)\n"
1683 " perror(\"select()\");\n"
1684 " else if (retval)\n"
1685 " printf(\"Dane są już dostępne.\\[rs]n\");\n"
1686 " /* FD_ISSET(0, &rfds) będzie prawdziwy. */\n"
1687 " else\n"
1688 " printf(\"Brak danych w ciągu pięciu sekund.\\[rs]n\");\n"
1689 "\\&\n"
1690 " exit(EXIT_SUCCESS);\n"
1691 "}\n"
1692
1693 #. type: TH
1694 #: mageia-cauldron
1695 #, no-wrap
1696 msgid "Linux man-pages 6.17"
1697 msgstr "Linux man-pages 6.17"
1698
1699 #. type: TH
1700 #: opensuse-leap-16-1 opensuse-tumbleweed
1701 #, no-wrap
1702 msgid "Linux man-pages (unreleased)"
1703 msgstr "Linux man-pages (niewydane)"