Debian Codegraph @

po/ar/man2/select.2.po

raw
1 # Arabic translation of manpages
2 # This file is distributed under the same license as the manpages-l10n package.
3 # Copyright © of this file:
4 # زايد السعيدي <[email protected]>, 2026.
5 msgid ""
6 msgstr ""
7 "Project-Id-Version: manpages-l10n\n"
8 "POT-Creation-Date: 2026-06-05 06:42+0200\n"
9 "PO-Revision-Date: 2026-06-03 04:49+0400\n"
10 "Last-Translator: Zayed Al-Saidi <[email protected]>\n"
11 "Language-Team: Arabic <[email protected]>\n"
12 "Language: ar\n"
13 "MIME-Version: 1.0\n"
14 "Content-Type: text/plain; charset=UTF-8\n"
15 "Content-Transfer-Encoding: 8bit\n"
16 ".MIME-Version: 1.0\n"
17 "Plural-Forms: nplurals=6; plural=n==0 ? 0 : n==1 ? 1 : n==2 ? 2 : n%100>=3 "
18 "&& n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n"
19 "X-Generator: Lokalize 23.08.5\n"
20
21 #. type: TH
22 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
23 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
24 #, no-wrap
25 msgid "select"
26 msgstr "select"
27
28 #. type: TH
29 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
30 #: opensuse-tumbleweed
31 #, no-wrap
32 msgid "2026-02-08"
33 msgstr "8 فبراير 2026"
34
35 #. type: TH
36 #: archlinux debian-unstable
37 #, no-wrap
38 msgid "Linux man-pages 6.18"
39 msgstr "صفحات دليل لينكس 6.18"
40
41 #. type: SH
42 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
43 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
44 #, no-wrap
45 msgid "NAME"
46 msgstr "الاسم"
47
48 #. type: Plain text
49 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
50 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
51 msgid ""
52 "select, pselect, FD_CLR, FD_ISSET, FD_SET, FD_ZERO, fd_set - synchronous I/O "
53 "multiplexing"
54 msgstr ""
55 "select, pselect, FD_CLR, FD_ISSET, FD_SET, FD_ZERO, fd_set - تعدد الإرسال "
56 "المتزامن للإدخال/الإخراج"
57
58 #. type: SH
59 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
60 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
61 #, no-wrap
62 msgid "LIBRARY"
63 msgstr "المكتبة"
64
65 #. type: Plain text
66 #: archlinux debian-unstable fedora-44 fedora-rawhide mageia-cauldron
67 #: opensuse-leap-16-1 opensuse-tumbleweed
68 msgid "Standard C library (I<libc>,\\ I<-lc>)"
69 msgstr "مكتبة سي المعيارية (I<libc>،\\ I<-lc>)"
70
71 #. type: SH
72 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
73 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
74 #, no-wrap
75 msgid "SYNOPSIS"
76 msgstr "موجز"
77
78 #. type: Plain text
79 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
80 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
81 #, no-wrap
82 msgid "B<#include E<lt>sys/select.hE<gt>>\n"
83 msgstr "B<#include E<lt>sys/select.hE<gt>>\n"
84
85 #. type: Plain text
86 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
87 #: opensuse-tumbleweed
88 #, no-wrap
89 msgid "B<typedef> /* .\\|.\\|.\\& */ B<fd_set;>\n"
90 msgstr "B<typedef> /* .\\|.\\|.\\& */ B<fd_set;>\n"
91
92 #. type: Plain text
93 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
94 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
95 #, no-wrap
96 msgid ""
97 "B<int select(int >I<nfds>B<, fd_set *_Nullable restrict >I<readfds>B<,>\n"
98 "B< fd_set *_Nullable restrict >I<writefds>B<,>\n"
99 "B< fd_set *_Nullable restrict >I<exceptfds>B<,>\n"
100 "B< struct timeval *_Nullable restrict >I<timeout>B<);>\n"
101 msgstr ""
102 "B<int select(int >I<nfds>B<, fd_set *_Nullable restrict >I<readfds>B<,>\n"
103 "B< fd_set *_Nullable restrict >I<writefds>B<,>\n"
104 "B< fd_set *_Nullable restrict >I<exceptfds>B<,>\n"
105 "B< struct timeval *_Nullable restrict >I<timeout>B<);>\n"
106
107 #. type: Plain text
108 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
109 #: opensuse-tumbleweed
110 #, no-wrap
111 msgid ""
112 "B<void FD_CLR(int >I<fd>B<, fd_set *>I<set>B<);>\n"
113 "B<int FD_ISSET(int >I<fd>B<, const fd_set *>I<set>B<);>\n"
114 "B<void FD_SET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
115 "B<void FD_ZERO(fd_set *>I<set>B<);>\n"
116 msgstr ""
117 "B<void FD_CLR(int >I<fd>B<, fd_set *>I<set>B<);>\n"
118 "B<int FD_ISSET(int >I<fd>B<, const fd_set *>I<set>B<);>\n"
119 "B<void FD_SET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
120 "B<void FD_ZERO(fd_set *>I<set>B<);>\n"
121
122 #. type: Plain text
123 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
124 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
125 #, no-wrap
126 msgid ""
127 "B<int pselect(int >I<nfds>B<, fd_set *_Nullable restrict >I<readfds>B<,>\n"
128 "B< fd_set *_Nullable restrict >I<writefds>B<,>\n"
129 "B< fd_set *_Nullable restrict >I<exceptfds>B<,>\n"
130 "B< const struct timespec *_Nullable restrict >I<timeout>B<,>\n"
131 "B< const sigset_t *_Nullable restrict >I<sigmask>B<);>\n"
132 msgstr ""
133 "B<int pselect(int >I<nfds>B<, fd_set *_Nullable restrict >I<readfds>B<,>\n"
134 "B< fd_set *_Nullable restrict >I<writefds>B<,>\n"
135 "B< fd_set *_Nullable restrict >I<exceptfds>B<,>\n"
136 "B< const struct timespec *_Nullable restrict >I<timeout>B<,>\n"
137 "B< const sigset_t *_Nullable restrict >I<sigmask>B<);>\n"
138
139 #. type: Plain text
140 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
141 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
142 msgid ""
143 "Feature Test Macro Requirements for glibc (see B<feature_test_macros>(7)):"
144 msgstr ""
145 "متطلبات ماكروات اختبار الميزات لـ glibc (انظر B<feature_test_macros>(7)):"
146
147 #. type: Plain text
148 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
149 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
150 msgid "B<pselect>():"
151 msgstr "B<pselect>():"
152
153 #. type: Plain text
154 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
155 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
156 #, no-wrap
157 msgid " _POSIX_C_SOURCE E<gt>= 200112L\n"
158 msgstr " _POSIX_C_SOURCE E<gt>= 200112L\n"
159
160 #. type: SH
161 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
162 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
163 #, no-wrap
164 msgid "DESCRIPTION"
165 msgstr "الوصف"
166
167 #. type: Plain text
168 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
169 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
170 msgid ""
171 "B<WARNING>: B<select>() can monitor only file descriptors numbers that are "
172 "less than B<FD_SETSIZE> (1024)\\[em]an unreasonably low limit for many "
173 "modern applications\\[em]and this limitation will not change. All modern "
174 "applications should instead use B<poll>(2) or B<epoll>(7), which do not "
175 "suffer this limitation."
176 msgstr ""
177 "B<تحذير>: B<select>() يمكنه مراقبة أرقام واصفات الملفات الأقل من "
178 "B<FD_SETSIZE> (1024) فقط\\[em]حد منخفض بشكل غير معقول للعديد من التطبيقات "
179 "الحديثة\\[em]وهذا القيد لن يتغير. يجب على جميع التطبيقات الحديثة استخدام "
180 "B<poll>(2) أو B<epoll>(7) بدلاً من ذلك، والتي لا تعاني من هذا القيد."
181
182 #. type: Plain text
183 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
184 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
185 msgid ""
186 "B<select>() allows a program to monitor multiple file descriptors, waiting "
187 "until one or more of the file descriptors become \"ready\" for some class of "
188 "I/O operation (e.g., input possible). A file descriptor is considered ready "
189 "if it is possible to perform a corresponding I/O operation (e.g., "
190 "B<read>(2), or a sufficiently small B<write>(2)) without blocking."
191 msgstr ""
192 "B<select>() يسمح للبرنامج بمراقبة واصفات ملفات متعددة، منتظراً حتى يصبح واحد "
193 "أو أكثر من واصفات الملفات \"جاهزاً\" لفئة معينة من عمليات الإدخال/الإخراج "
194 "(مثل، إدخال ممكن). يعتبر واصف الملف جاهزاً إذا كان من الممكن تنفيذ عملية "
195 "إدخال/إخراج مقابلة (مثل، B<read>(2)، أو B<write>(2) صغير بما يكفي) دون حظر."
196
197 #. type: SS
198 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
199 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
200 #, no-wrap
201 msgid "fd_set"
202 msgstr "fd_set"
203
204 #. type: Plain text
205 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
206 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
207 msgid ""
208 "A structure type that can represent a set of file descriptors. According to "
209 "POSIX, the maximum number of file descriptors in an I<fd_set> structure is "
210 "the value of the macro B<FD_SETSIZE>."
211 msgstr ""
212 "نوع بنية يمكنه تمثيل مجموعة من واصفات الملفات. وفقاً لـ POSIX، الحد الأقصى "
213 "لعدد واصفات الملفات في بنية I<fd_set> هو قيمة الماكرو B<FD_SETSIZE>."
214
215 #. type: SS
216 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
217 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
218 #, no-wrap
219 msgid "File descriptor sets"
220 msgstr "مجموعات واصفات الملفات"
221
222 #. type: Plain text
223 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
224 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
225 msgid ""
226 "The principal arguments of B<select>() are three \"sets\" of file "
227 "descriptors (declared with the type I<fd_set>), which allow the caller to "
228 "wait for three classes of events on the specified set of file descriptors. "
229 "Each of the I<fd_set> arguments may be specified as NULL if no file "
230 "descriptors are to be watched for the corresponding class of events."
231 msgstr ""
232 "الوسائط الرئيسية لـ B<select>() هي ثلاث \"مجموعات\" من واصفات الملفات "
233 "(مُعلنة بالنوع I<fd_set>)، والتي تسمح للمستدعي بالانتظار لثلاث فئات من "
234 "الأحداث على مجموعة واصفات الملفات المحددة. يمكن تحديد كل وسيطة من I<fd_set> "
235 "كـ NULL إذا لم تكن هناك واصفات ملفات يجب مراقبتها لفئة الأحداث المقابلة."
236
237 #. type: Plain text
238 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
239 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
240 msgid ""
241 "B<Note well>: Upon return, each of the file descriptor sets is modified in "
242 "place to indicate which file descriptors are currently \"ready\". Thus, if "
243 "using B<select>() within a loop, the sets I<must be reinitialized> before "
244 "each call."
245 msgstr ""
246 "B<ملاحظة مهمة>: عند العودة، يتم تعديل كل مجموعة من مجموعات واصفات الملفات في "
247 "مكانها للإشارة إلى واصفات الملفات الجاهزة حالياً. وبالتالي، إذا تم استخدام "
248 "B<select>() داخل حلقة، يجب I<إعادة تهيئة> المجموعات قبل كل استدعاء."
249
250 #. type: Plain text
251 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
252 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
253 msgid ""
254 "The contents of a file descriptor set can be manipulated using the following "
255 "macros:"
256 msgstr "يمكن معالجة محتويات مجموعة واصفات الملفات باستخدام الماكرو التالية:"
257
258 #. type: TP
259 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
260 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
261 #, no-wrap
262 msgid "B<FD_ZERO>()"
263 msgstr "B<FD_ZERO>()"
264
265 #. type: Plain text
266 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
267 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
268 msgid ""
269 "This macro clears (removes all file descriptors from) I<set>. It should be "
270 "employed as the first step in initializing a file descriptor set."
271 msgstr ""
272 "يقوم هذا الماكرو بمسح (إزالة جميع واصفات الملفات من) I<set>. يجب استخدامه "
273 "كخطوة أولى في تهيئة مجموعة واصفات الملفات."
274
275 #. type: TP
276 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
277 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
278 #, no-wrap
279 msgid "B<FD_SET>()"
280 msgstr "B<FD_SET>()"
281
282 #. type: Plain text
283 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
284 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
285 msgid ""
286 "This macro adds the file descriptor I<fd> to I<set>. Adding a file "
287 "descriptor that is already present in the set is a no-op, and does not "
288 "produce an error."
289 msgstr ""
290 "يضيف هذا الماكرو واصف الملف I<fd> إلى I<set>. إضافة واصف ملف موجود بالفعل "
291 "في المجموعة هو عملية عدم فعل، ولا ينتج عنه خطأ."
292
293 #. type: TP
294 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
295 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
296 #, no-wrap
297 msgid "B<FD_CLR>()"
298 msgstr "B<FD_CLR>()"
299
300 #. type: Plain text
301 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
302 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
303 msgid ""
304 "This macro removes the file descriptor I<fd> from I<set>. Removing a file "
305 "descriptor that is not present in the set is a no-op, and does not produce "
306 "an error."
307 msgstr ""
308 "يزيل هذا الماكرو واصف الملف I<fd> من I<set>. إزالة واصف ملف غير موجود في "
309 "المجموعة هو عملية عدم فعل، ولا ينتج عنه خطأ."
310
311 #. type: TP
312 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
313 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
314 #, no-wrap
315 msgid "B<FD_ISSET>()"
316 msgstr "B<FD_ISSET>()"
317
318 #. type: Plain text
319 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
320 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
321 msgid ""
322 "B<select>() modifies the contents of the sets according to the rules "
323 "described below. After calling B<select>(), the B<FD_ISSET>() macro can be "
324 "used to test if a file descriptor is still present in a set. B<FD_ISSET>() "
325 "returns nonzero if the file descriptor I<fd> is present in I<set>, and zero "
326 "if it is not."
327 msgstr ""
328 "يقوم B<select>() بتعديل محتويات المجموعات وفقاً للقواعد الموصوفة أدناه. بعد "
329 "استدعاء B<select>()، يمكن استخدام الماكرو B<FD_ISSET>() لاختبار ما إذا كان "
330 "واصف الملف لا يزال موجوداً في مجموعة. يُرجع B<FD_ISSET>() قيمة غير صفرية إذا "
331 "كان واصف الملف I<fd> موجوداً في I<set>، وصفراً إذا لم يكن كذلك."
332
333 #. type: SS
334 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
335 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
336 #, no-wrap
337 msgid "Arguments"
338 msgstr "المعطيات"
339
340 #. type: Plain text
341 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
342 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
343 msgid "The arguments of B<select>() are as follows:"
344 msgstr "وسائط B<select>() هي كما يلي:"
345
346 #. type: TP
347 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
348 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
349 #, no-wrap
350 msgid "I<readfds>"
351 msgstr "I<readfds>"
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 ""
357 "The file descriptors in this set are watched to see if they are ready for "
358 "reading. A file descriptor is ready for reading if a read operation will "
359 "not block; in particular, a file descriptor is also ready on end-of-file."
360 msgstr ""
361 "يتم مراقبة واصفات الملفات في هذه المجموعة لمعرفة ما إذا كانت جاهزة للقراءة. "
362 "واصف الملف جاهز للقراءة إذا كانت عملية القراءة لن تحظر؛ على وجه الخصوص، واصف "
363 "الملف جاهز أيضًا عند نهاية الملف."
364
365 #. type: Plain text
366 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
367 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
368 msgid ""
369 "After B<select>() has returned, I<readfds> will be cleared of all file "
370 "descriptors except for those that are ready for reading."
371 msgstr ""
372 "بعد أن يعود B<select>()، سيتم مسح I<readfds> من جميع واصفات الملفات باستثناء "
373 "تلك الجاهزة للقراءة."
374
375 #. type: TP
376 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
377 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
378 #, no-wrap
379 msgid "I<writefds>"
380 msgstr "I<writefds>"
381
382 #. type: Plain text
383 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
384 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
385 msgid ""
386 "The file descriptors in this set are watched to see if they are ready for "
387 "writing. A file descriptor is ready for writing if a write operation will "
388 "not block. However, even if a file descriptor indicates as writable, a "
389 "large write may still block."
390 msgstr ""
391 "يتم مراقبة واصفات الملفات في هذه المجموعة لمعرفة ما إذا كانت جاهزة للكتابة. "
392 "واصف الملف جاهز للكتابة إذا كانت عملية الكتابة لن تحظر. ومع ذلك، حتى إذا "
393 "أشار واصف الملف إلى أنه قابل للكتابة، فقد تظل الكتابة الكبيرة تحظر."
394
395 #. type: Plain text
396 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
397 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
398 msgid ""
399 "After B<select>() has returned, I<writefds> will be cleared of all file "
400 "descriptors except for those that are ready for writing."
401 msgstr ""
402 "بعد أن يعود B<select>()، سيتم مسح I<writefds> من جميع واصفات الملفات "
403 "باستثناء تلك الجاهزة للكتابة."
404
405 #. type: TP
406 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
407 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
408 #, no-wrap
409 msgid "I<exceptfds>"
410 msgstr "I<exceptfds>"
411
412 #. type: Plain text
413 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
414 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
415 msgid ""
416 "The file descriptors in this set are watched for \"exceptional "
417 "conditions\". For examples of some exceptional conditions, see the "
418 "discussion of B<POLLPRI> in B<poll>(2)."
419 msgstr ""
420 "يتم مراقبة واصفات الملفات في هذه المجموعة لـ \"ظروف استثنائية\". للحصول على "
421 "أمثلة لبعض الظروف الاستثنائية، انظر مناقشة B<POLLPRI> في B<poll>(2)."
422
423 #. type: Plain text
424 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
425 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
426 msgid ""
427 "After B<select>() has returned, I<exceptfds> will be cleared of all file "
428 "descriptors except for those for which an exceptional condition has occurred."
429 msgstr ""
430 "بعد أن يعود B<select>()، سيتم مسح I<exceptfds> من جميع واصفات الملفات "
431 "باستثناء تلك التي حدثت لها حالة استثنائية."
432
433 #. type: TP
434 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
435 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
436 #, no-wrap
437 msgid "I<nfds>"
438 msgstr "I<nfds>"
439
440 #. type: Plain text
441 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
442 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
443 msgid ""
444 "This argument should be set to the highest-numbered file descriptor in any "
445 "of the three sets, plus 1. The indicated file descriptors in each set are "
446 "checked, up to this limit (but see BUGS)."
447 msgstr ""
448 "يجب تعيين هذه الوسيطة إلى أعلى واصف ملف مرقم في أي من المجموعات الثلاث، زائد "
449 "1. يتم فحص واصفات الملفات المشار إليها في كل مجموعة، حتى هذا الحد (ولكن "
450 "انظر الأخطاء)."
451
452 #. type: TP
453 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
454 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
455 #, no-wrap
456 msgid "I<timeout>"
457 msgstr "I<timeout>"
458
459 #. type: Plain text
460 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
461 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
462 msgid ""
463 "The I<timeout> argument is a I<timeval> structure (shown below) that "
464 "specifies the interval that B<select>() should block waiting for a file "
465 "descriptor to become ready. The call will block until either:"
466 msgstr ""
467 "وسيطة I<timeout> هي بنية I<timeval> (موضحة أدناه) تحدد الفاصل الزمني الذي "
468 "يجب أن يحظر فيه B<select>() منتظراً حتى يصبح واصف الملف جاهزاً. سوف يحظر "
469 "الاستدعاء حتى:"
470
471 #. type: IP
472 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
473 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
474 #, no-wrap
475 msgid "\\[bu]"
476 msgstr "\\[bu]"
477
478 #. type: Plain text
479 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
480 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
481 msgid "a file descriptor becomes ready;"
482 msgstr "يصبح واصف الملف جاهزًا؛"
483
484 #. type: Plain text
485 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
486 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
487 msgid "the call is interrupted by a signal handler; or"
488 msgstr "الاستدعاء قوطع بواسطة معالج إشارة؛ أو"
489
490 #. type: Plain text
491 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
492 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
493 msgid "the timeout expires."
494 msgstr "انتهاء المهلة."
495
496 #. type: Plain text
497 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
498 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
499 msgid ""
500 "Note that the I<timeout> interval will be rounded up to the system clock "
501 "granularity, and kernel scheduling delays mean that the blocking interval "
502 "may overrun by a small amount."
503 msgstr ""
504 "لاحظ أن فاصل I<timeout> سيتم تقريبه لأعلى إلى دقة ساعة النظام، وتأخيرات "
505 "جدولة النواة تعني أن فاصل الحظر قد يتجاوز بمقدار صغير."
506
507 #. type: Plain text
508 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
509 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
510 msgid ""
511 "If both fields of the I<timeval> structure are zero, then B<select>() "
512 "returns immediately. (This is useful for polling.)"
513 msgstr ""
514 "إذا كان كلا حقلي بنية I<timeval> صفراً، فإن B<select>() يعود فوراً. (هذا "
515 "مفيد للاستقصاء.)"
516
517 #. type: Plain text
518 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
519 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
520 msgid ""
521 "If I<timeout> is specified as NULL, B<select>() blocks indefinitely waiting "
522 "for a file descriptor to become ready."
523 msgstr ""
524 "إذا تم تحديد I<timeout> كـ NULL، فإن B<select>() يحظر إلى أجل غير مسمى "
525 "منتظراً حتى يصبح واصف الملف جاهزاً."
526
527 #. type: SS
528 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
529 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
530 #, no-wrap
531 msgid "pselect()"
532 msgstr "pselect()"
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 "The B<pselect>() system call allows an application to safely wait until "
539 "either a file descriptor becomes ready or until a signal is caught."
540 msgstr ""
541 "استدعاء النظام B<pselect>() يسمح للتطبيق بالانتظار بأمان حتى يصبح واصف "
542 "الملف جاهزاً أو حتى يتم التقاط إشارة."
543
544 #. type: Plain text
545 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
546 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
547 msgid ""
548 "The operation of B<select>() and B<pselect>() is identical, other than "
549 "these three differences:"
550 msgstr ""
551 "عملية B<select>() و B<pselect>() متطابقة، باستثناء هذه الاختلافات الثلاثة:"
552
553 #. type: Plain text
554 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
555 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
556 msgid ""
557 "B<select>() uses a timeout that is a I<struct timeval> (with seconds and "
558 "microseconds), while B<pselect>() uses a I<struct timespec> (with seconds "
559 "and nanoseconds)."
560 msgstr ""
561 "تستخدم B<select>() مهلة زمنية من النوع I<struct timeval> (مع الثواني "
562 "والميكروثواني)، بينما تستخدم B<pselect>() النوع I<struct timespec> (مع "
563 "الثواني والنانوثواني)."
564
565 #. type: Plain text
566 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
567 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
568 msgid ""
569 "B<select>() may update the I<timeout> argument to indicate how much time "
570 "was left. B<pselect>() does not change this argument."
571 msgstr ""
572 "قد تحدّث B<select>() الوسيط I<timeout> للإشارة إلى مقدار الوقت المتبقي. لا "
573 "تغيّر B<pselect>() هذه الوسيط."
574
575 #. type: Plain text
576 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
577 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
578 msgid ""
579 "B<select>() has no I<sigmask> argument, and behaves as B<pselect>() called "
580 "with NULL I<sigmask>."
581 msgstr ""
582 "لا تحتوي B<select>() على وسيط I<sigmask>، وتتصرف مثل B<pselect>() التي "
583 "استُدعيت مع I<sigmask> بقيمة NULL."
584
585 #. type: Plain text
586 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
587 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
588 msgid ""
589 "I<sigmask> is a pointer to a signal mask (see B<sigprocmask>(2)); if it is "
590 "not NULL, then B<pselect>() first replaces the current signal mask by the "
591 "one pointed to by I<sigmask>, then does the \"select\" function, and then "
592 "restores the original signal mask. (If I<sigmask> is NULL, the signal mask "
593 "is not modified during the B<pselect>() call.)"
594 msgstr ""
595 "I<sigmask> هو مؤشر لقناع إشارة (انظر B<sigprocmask>(2))؛ إذا لم يكن NULL، "
596 "فإن B<pselect>() تستبدل أولاً قناع الإشارة الحالي بالقناع المشار إليه بواسطة "
597 "I<sigmask>، ثم تؤدي وظيفة \"select\"، ثم تستعيد قناع الإشارة الأصلي. (إذا "
598 "كان I<sigmask> هو NULL، لا يُعدّل قناع الإشارة أثناء استدعاء B<pselect>().)"
599
600 #. type: Plain text
601 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
602 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
603 msgid ""
604 "Other than the difference in the precision of the I<timeout> argument, the "
605 "following B<pselect>() call:"
606 msgstr ""
607 "بخلاف الاختلاف في دقة وسيط I<timeout>، فإن استدعاء B<pselect>() التالي:"
608
609 #. type: Plain text
610 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
611 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
612 #, no-wrap
613 msgid ""
614 "ready = pselect(nfds, &readfds, &writefds, &exceptfds,\n"
615 " timeout, &sigmask);\n"
616 msgstr ""
617 "ready = pselect(nfds, &readfds, &writefds, &exceptfds,\n"
618 " timeout, &sigmask);\n"
619
620 #. type: Plain text
621 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
622 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
623 msgid "is equivalent to I<atomically> executing the following calls:"
624 msgstr "يعادل تنفيذ الاستدعاءات التالية I<بشكل ذري>:"
625
626 #. type: Plain text
627 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
628 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
629 #, no-wrap
630 msgid ""
631 "sigset_t origmask;\n"
632 "\\&\n"
633 "pthread_sigmask(SIG_SETMASK, &sigmask, &origmask);\n"
634 "ready = select(nfds, &readfds, &writefds, &exceptfds, timeout);\n"
635 "pthread_sigmask(SIG_SETMASK, &origmask, NULL);\n"
636 msgstr ""
637 "sigset_t origmask;\n"
638 "\\&\n"
639 "pthread_sigmask(SIG_SETMASK, &sigmask, &origmask);\n"
640 "ready = select(nfds, &readfds, &writefds, &exceptfds, timeout);\n"
641 "pthread_sigmask(SIG_SETMASK, &origmask, NULL);\n"
642
643 #. type: Plain text
644 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
645 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
646 msgid ""
647 "The reason that B<pselect>() is needed is that if one wants to wait for "
648 "either a signal or for a file descriptor to become ready, then an atomic "
649 "test is needed to prevent race conditions. (Suppose the signal handler sets "
650 "a global flag and returns. Then a test of this global flag followed by a "
651 "call of B<select>() could hang indefinitely if the signal arrived just "
652 "after the test but just before the call. By contrast, B<pselect>() allows "
653 "one to first block signals, handle the signals that have come in, then call "
654 "B<pselect>() with the desired I<sigmask>, avoiding the race.)"
655 msgstr ""
656 "سبب الحاجة إلى B<pselect>() هو أنه إذا أراد المرء الانتظار إما لإشارة أو "
657 "لوصف ملف ليصبح جاهزًا، فإن اختبارًا ذريًا ضروري لمنع حالات السباق. (افترض أن "
658 "معالج الإشارة يضع علامة عامة ويعود. ثم اختبار هذه العلامة العامة متبوعًا "
659 "باستدعاء B<select>() قد يتعطل إلى أجل غير مسمى إذا وصلت الإشارة بعد "
660 "الاختبار مباشرة ولكن قبل الاستدعاء. على النقيض، تسمح B<pselect>() للمرء "
661 "أولاً بحظر الإشارات، ومعالجة الإشارات التي وصلت، ثم استدعاء B<pselect>() مع "
662 "I<sigmask> المطلوب، متجنبًا السباق.)"
663
664 #. type: SS
665 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
666 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
667 #, no-wrap
668 msgid "The timeout"
669 msgstr "المهلة الزمنية"
670
671 #. type: Plain text
672 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
673 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
674 msgid ""
675 "The I<timeout> argument for B<select>() is a structure of the following "
676 "type:"
677 msgstr "وسيط I<timeout> لـ B<select>() هو بنية من النوع التالي:"
678
679 #. type: Plain text
680 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
681 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
682 #, no-wrap
683 msgid ""
684 "struct timeval {\n"
685 " time_t tv_sec; /* seconds */\n"
686 " suseconds_t tv_usec; /* microseconds */\n"
687 "};\n"
688 msgstr ""
689 "struct timeval {\n"
690 " time_t tv_sec; /* seconds */\n"
691 " suseconds_t tv_usec; /* microseconds */\n"
692 "};\n"
693
694 #. type: Plain text
695 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
696 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
697 msgid ""
698 "The corresponding argument for B<pselect>() is a B<timespec>(3) structure."
699 msgstr "الوسيط المقابل لـ B<pselect>() هو بنية B<timespec>(3)."
700
701 #. .P - it is rumored that:
702 #. On BSD, when a timeout occurs, the file descriptor bits are not changed.
703 #. - it is certainly true that:
704 #. Linux follows SUSv2 and sets the bit masks to zero upon a timeout.
705 #. type: Plain text
706 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
707 #: opensuse-tumbleweed
708 msgid ""
709 "On Linux, B<select>() modifies I<timeout> to reflect the amount of time not "
710 "slept; most other implementations do not do this. (POSIX.1 permits either "
711 "behavior.) This causes problems both when Linux code which reads I<timeout> "
712 "is ported to other operating systems, and when code is ported to Linux that "
713 "reuses a I<struct\\ timeval> for multiple B<select>()s in a loop without "
714 "reinitializing it. Consider I<timeout> to be undefined after B<select>() "
715 "returns."
716 msgstr ""
717 "في لينكس، تعدل B<select>() I<timeout> لتعكس مقدار الوقت غير المُنام؛ معظم "
718 "التطبيقات الأخرى لا تفعل هذا. (يسمح POSIX.1 بأي من السلوكين.) يسبب هذا "
719 "مشاكل سواء عندما يُنقل كود لينكس الذي يقرأ I<timeout> إلى أنظمة تشغيل أخرى، "
720 "وعندما يُنقل كود إلى لينكس يعيد استخدام I<struct\\ timeval> لعدة B<select>()s "
721 "في حلقة دون إعادة تهيئته. اعتبر I<timeout> غير معرف بعد عودة B<select>()."
722
723 #. type: SH
724 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
725 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
726 #, no-wrap
727 msgid "RETURN VALUE"
728 msgstr "قيمة الإرجاع"
729
730 #. type: Plain text
731 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
732 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
733 msgid ""
734 "On success, B<select>() and B<pselect>() return the number of file "
735 "descriptors contained in the three returned descriptor sets (that is, the "
736 "total number of bits that are set in I<readfds>, I<writefds>, "
737 "I<exceptfds>). The return value may be zero if the timeout expired before "
738 "any file descriptors became ready."
739 msgstr ""
740 "عند النجاح، تُرجع B<select>() و B<pselect>() عدد واصفات الملفات الموجودة في "
741 "مجموعات الواصفات الثلاث المُعادة (أي العدد الإجمالي للبتات المُعيّنة في "
742 "I<readfds> و I<writefds> و I<exceptfds>). قد تكون قيمة الإرجاع صفرًا إذا "
743 "انتهت المهلة الزمنية قبل أن يصبح أي واصف ملف جاهزًا."
744
745 #. type: Plain text
746 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
747 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
748 msgid ""
749 "On error, -1 is returned, and I<errno> is set to indicate the error; the "
750 "file descriptor sets are unmodified, and I<timeout> becomes undefined."
751 msgstr ""
752 "عند الخطأ، تُعاد -1، ويُعيّن I<errno> للإشارة إلى الخطأ؛ تبقى مجموعات واصفات "
753 "الملفات دون تعديل، ويصبح I<timeout> غير معرف."
754
755 #. type: SH
756 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
757 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
758 #, no-wrap
759 msgid "ERRORS"
760 msgstr "الأخطاء"
761
762 #. type: TP
763 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
764 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
765 #, no-wrap
766 msgid "B<EBADF>"
767 msgstr "B<EBADF>"
768
769 #. type: Plain text
770 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
771 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
772 msgid ""
773 "An invalid file descriptor was given in one of the sets. (Perhaps a file "
774 "descriptor that was already closed, or one on which an error has occurred.) "
775 "However, see BUGS."
776 msgstr ""
777 "وُجد واصف ملف غير صالح في إحدى المجموعات. (ربما واصف ملف أُغلق بالفعل، أو واصف "
778 "حدث فيه خطأ.) ومع ذلك، انظر الأخطاء."
779
780 #. type: TP
781 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
782 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
783 #, no-wrap
784 msgid "B<EINTR>"
785 msgstr "B<EINTR>"
786
787 #. type: Plain text
788 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
789 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
790 msgid "A signal was caught; see B<signal>(7)."
791 msgstr "اُلتُقطت إشارة؛ انظر B<signal>(7)."
792
793 #. type: TP
794 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
795 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
796 #, no-wrap
797 msgid "B<EINVAL>"
798 msgstr "B<EINVAL>"
799
800 #. type: Plain text
801 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
802 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
803 msgid ""
804 "I<nfds> is negative or exceeds the B<RLIMIT_NOFILE> resource limit (see "
805 "B<getrlimit>(2))."
806 msgstr ""
807 "I<nfds> سالب أو يتجاوز حد المورد B<RLIMIT_NOFILE> (انظر B<getrlimit>(2))."
808
809 #. type: Plain text
810 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
811 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
812 msgid "The value contained within I<timeout> is invalid."
813 msgstr "القيمة الموجودة داخل I<timeout> غير صالحة."
814
815 #. type: TP
816 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
817 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
818 #, no-wrap
819 msgid "B<ENOMEM>"
820 msgstr "B<ENOMEM>"
821
822 #. type: Plain text
823 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
824 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
825 msgid "Unable to allocate memory for internal tables."
826 msgstr "غير قادر على تخصيص ذاكرة للجداول الداخلية."
827
828 #. type: SH
829 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
830 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
831 #, no-wrap
832 msgid "VERSIONS"
833 msgstr "الإصدارات"
834
835 #. Darwin, according to a report by Jeremy Sequoia, relayed by Josh Triplett
836 #. type: Plain text
837 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
838 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
839 msgid ""
840 "On some other UNIX systems, B<select>() can fail with the error B<EAGAIN> "
841 "if the system fails to allocate kernel-internal resources, rather than "
842 "B<ENOMEM> as Linux does. POSIX specifies this error for B<poll>(2), but not "
843 "for B<select>(). Portable programs may wish to check for B<EAGAIN> and "
844 "loop, just as with B<EINTR>."
845 msgstr ""
846 "في بعض أنظمة UNIX الأخرى، قد تفشل B<select>() مع الخطأ B<EAGAIN> إذا فشل "
847 "النظام في تخصيص موارد داخلية للنواة، بدلاً من B<ENOMEM> كما يفعل لينكس. يحدد "
848 "POSIX هذا الخطأ لـ B<poll>(2)، ولكن ليس لـ B<select>(). قد ترغب البرامج "
849 "المحمولة في التحقق من B<EAGAIN> والتكرار، تمامًا كما هو الحال مع B<EINTR>."
850
851 #. type: SH
852 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
853 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
854 #, no-wrap
855 msgid "STANDARDS"
856 msgstr "المعايير"
857
858 #. type: Plain text
859 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
860 #: opensuse-tumbleweed
861 msgid "POSIX.1-2024."
862 msgstr "POSIX.1-2024."
863
864 #. type: SH
865 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
866 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
867 #, no-wrap
868 msgid "HISTORY"
869 msgstr "التاريخ"
870
871 #. type: TP
872 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
873 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
874 #, no-wrap
875 msgid "B<select>()"
876 msgstr "B<select>()"
877
878 #. type: Plain text
879 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
880 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
881 msgid "POSIX.1-2001, 4.4BSD (first appeared in 4.2BSD)."
882 msgstr "POSIX.1-2001،‏ 4.4BSD (ظهر أولاً في 4.2BSD)."
883
884 #. type: Plain text
885 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
886 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
887 msgid ""
888 "Generally portable to/from non-BSD systems supporting clones of the BSD "
889 "socket layer (including System\\ V variants). However, note that the "
890 "System\\ V variant typically sets the timeout variable before returning, but "
891 "the BSD variant does not."
892 msgstr ""
893 "يمكن نقلها عمومًا من وإلى الأنظمة غير التابعة لنظام BSD التي تدعم نسخًا مطابقة "
894 "لطبقة مآخذ BSD (بما في ذلك متغيرات System V). ومع ذلك، تجدر الإشارة إلى أن "
895 "متغير System V عادةً ما يقوم بتعيين متغير المهلة قبل العودة، بينما لا يقوم "
896 "متغير BSD بذلك."
897
898 #. type: TP
899 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
900 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
901 #, no-wrap
902 msgid "B<pselect>()"
903 msgstr "B<pselect>()"
904
905 #. type: Plain text
906 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
907 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
908 msgid "Linux 2.6.16. POSIX.1g, POSIX.1-2001."
909 msgstr "لينكس 2.6.16. POSIX.1g, POSIX.1-2001."
910
911 #. type: Plain text
912 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
913 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
914 msgid "Prior to this, it was emulated in glibc (but see BUGS)."
915 msgstr "قبل ذلك، كان يُحاكى في glibc (ولكن انظر الأخطاء)."
916
917 #. type: TP
918 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
919 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
920 #, no-wrap
921 msgid "B<fd_set>"
922 msgstr "B<fd_set>"
923
924 #. type: Plain text
925 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
926 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
927 msgid "POSIX.1-2001."
928 msgstr "POSIX.1-2001."
929
930 #. type: SH
931 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
932 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
933 #, no-wrap
934 msgid "NOTES"
935 msgstr "ملاحظات"
936
937 #. type: Plain text
938 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
939 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
940 msgid ""
941 "The following header also provides the I<fd_set> type: I<E<lt>sys/time."
942 "hE<gt>>."
943 msgstr ""
944 "الملف الرأسي التالي يوفر أيضًا النوع I<fd_set>: I<E<lt>sys/time.hE<gt>>."
945
946 #. type: Plain text
947 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
948 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
949 msgid ""
950 "An I<fd_set> is a fixed size buffer. Executing B<FD_CLR>() or B<FD_SET>() "
951 "with a value of I<fd> that is negative or is equal to or larger than "
952 "B<FD_SETSIZE> will result in undefined behavior. Moreover, POSIX requires "
953 "I<fd> to be a valid file descriptor."
954 msgstr ""
955 "I<fd_set> هو مخزن ثابت الحجم. تنفيذ B<FD_CLR>() أو B<FD_SET>() بقيمة I<fd> "
956 "سالبة أو تساوي أو أكبر من B<FD_SETSIZE> سيؤدي إلى سلوك غير معرف. علاوة على "
957 "ذلك، يتطلب POSIX أن يكون I<fd> واصف ملف صالحًا."
958
959 #. type: Plain text
960 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
961 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
962 msgid ""
963 "The operation of B<select>() and B<pselect>() is not affected by the "
964 "B<O_NONBLOCK> flag."
965 msgstr "لا يتأثر تشغيل B<select>() و B<pselect>() بالعلامة B<O_NONBLOCK>."
966
967 #. type: SS
968 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
969 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
970 #, no-wrap
971 msgid "The self-pipe trick"
972 msgstr "خدعة الأنبوب الذاتي"
973
974 #. type: Plain text
975 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
976 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
977 msgid ""
978 "On systems that lack B<pselect>(), reliable (and more portable) signal "
979 "trapping can be achieved using the self-pipe trick. In this technique, a "
980 "signal handler writes a byte to a pipe whose other end is monitored by "
981 "B<select>() in the main program. (To avoid possibly blocking when writing "
982 "to a pipe that may be full or reading from a pipe that may be empty, "
983 "nonblocking I/O is used when reading from and writing to the pipe.)"
984 msgstr ""
985 "في الأنظمة التي تفتقر إلى B<pselect>()، يمكن تحقيق التقاط إشارة موثوق (وأكثر "
986 "قابلية للنقل) باستخدام خدعة الأنبوب الذاتي. في هذه التقنية، يكتب معالج "
987 "الإشارة بايتًا إلى أنبوب يُراقب طرفه الآخر بواسطة B<select>() في البرنامج "
988 "الرئيسي. (لتجنب الحظر المحتمل عند الكتابة إلى أنبوب قد يكون ممتلئًا أو "
989 "القراءة من أنبوب قد يكون فارغًا، يُستخدم الإدخال/الإخراج غير المحظور عند "
990 "القراءة من والكتابة إلى الأنبوب.)"
991
992 #. type: SS
993 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
994 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
995 #, no-wrap
996 msgid "Emulating usleep(3)"
997 msgstr "محاكاة usleep(3)"
998
999 #. type: Plain text
1000 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1001 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1002 msgid ""
1003 "Before the advent of B<usleep>(3), some code employed a call to B<select>() "
1004 "with all three sets empty, I<nfds> zero, and a non-NULL I<timeout> as a "
1005 "fairly portable way to sleep with subsecond precision."
1006 msgstr ""
1007 "قبل ظهور B<usleep>(3)، استخدم بعض الكود استدعاءً لـ B<select>() مع جميع "
1008 "المجموعات الثلاث فارغة، I<nfds> صفر، و I<timeout> غير NULL كطريقة قابلة "
1009 "للنقل بشكل معقول للنوم بدقة دون الثانية."
1010
1011 #. type: SS
1012 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1013 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1014 #, no-wrap
1015 msgid "Correspondence between select() and poll() notifications"
1016 msgstr "التوافق بين إشعارات select() و poll()"
1017
1018 #. fs/select.c
1019 #. type: Plain text
1020 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1021 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1022 msgid ""
1023 "Within the Linux kernel source, we find the following definitions which show "
1024 "the correspondence between the readable, writable, and exceptional condition "
1025 "notifications of B<select>() and the event notifications provided by "
1026 "B<poll>(2) and B<epoll>(7):"
1027 msgstr ""
1028 "داخل مصدر نواة لينكس، نجد التعريفات التالية التي تُظهر التوافق بين إشعارات "
1029 "الحالة القابلة للقراءة والقابلة للكتابة والاستثنائية لـ B<select>() "
1030 "وإشعارات الأحداث التي توفرها B<poll>(2) و B<epoll>(7):"
1031
1032 #. type: Plain text
1033 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1034 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1035 #, no-wrap
1036 msgid ""
1037 "#define POLLIN_SET (EPOLLRDNORM | EPOLLRDBAND | EPOLLIN |\n"
1038 " EPOLLHUP | EPOLLERR)\n"
1039 " /* Ready for reading */\n"
1040 "#define POLLOUT_SET (EPOLLWRBAND | EPOLLWRNORM | EPOLLOUT |\n"
1041 " EPOLLERR)\n"
1042 " /* Ready for writing */\n"
1043 "#define POLLEX_SET (EPOLLPRI)\n"
1044 " /* Exceptional condition */\n"
1045 msgstr ""
1046 "#define POLLIN_SET (EPOLLRDNORM | EPOLLRDBAND | EPOLLIN |\n"
1047 " EPOLLHUP | EPOLLERR)\n"
1048 " /* Ready for reading */\n"
1049 "#define POLLOUT_SET (EPOLLWRBAND | EPOLLWRNORM | EPOLLOUT |\n"
1050 " EPOLLERR)\n"
1051 " /* Ready for writing */\n"
1052 "#define POLLEX_SET (EPOLLPRI)\n"
1053 " /* Exceptional condition */\n"
1054
1055 #. type: SS
1056 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1057 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1058 #, no-wrap
1059 msgid "Multithreaded applications"
1060 msgstr "التطبيقات متعددة الخيوط"
1061
1062 #. type: Plain text
1063 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1064 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1065 msgid ""
1066 "If a file descriptor being monitored by B<select>() is closed in another "
1067 "thread, the result is unspecified. On some UNIX systems, B<select>() "
1068 "unblocks and returns, with an indication that the file descriptor is ready "
1069 "(a subsequent I/O operation will likely fail with an error, unless another "
1070 "process reopens the file descriptor between the time B<select>() returned "
1071 "and the I/O operation is performed). On Linux (and some other systems), "
1072 "closing the file descriptor in another thread has no effect on B<select>(). "
1073 "In summary, any application that relies on a particular behavior in this "
1074 "scenario must be considered buggy."
1075 msgstr ""
1076 "إذا أُغلق واصف ملف تراقبه B<select>() في خيط آخر، فالنتيجة غير محددة. في "
1077 "بعض أنظمة UNIX، تفك B<select>() الحظر وتعود، مع إشارة أن واصف الملف جاهز "
1078 "(ستفشل عملية الإدخال/الإخراج اللاحقة غالبًا بخطأ، ما لم يفتح عملية أخرى واصف "
1079 "الملف بين وقت عودة B<select>() وتنفيذ عملية الإدخال/الإخراج). في لينكس "
1080 "(وبعض الأنظمة الأخرى)، لا يؤثر إغلاق واصف الملف في خيط آخر على B<select>(). "
1081 "باختصار، أي تطبيق يعتمد على سلوك معين في هذا السيناريو يجب اعتباره معطوبًا."
1082
1083 #. type: SS
1084 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1085 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1086 #, no-wrap
1087 msgid "C library/kernel differences"
1088 msgstr "الاختلافات بين مكتبة C والنواة"
1089
1090 #. type: Plain text
1091 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1092 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1093 msgid ""
1094 "The Linux kernel allows file descriptor sets of arbitrary size, determining "
1095 "the length of the sets to be checked from the value of I<nfds>. However, in "
1096 "the glibc implementation, the I<fd_set> type is fixed in size. See also "
1097 "BUGS."
1098 msgstr ""
1099 "يسمح نواة لينكس بمجموعات واصفات ملفات ذات حجم عشوائي، محددًا طول المجموعات "
1100 "المراد فحصها من قيمة I<nfds>. لكن، في تطبيق glibc، النوع I<fd_set> ثابت "
1101 "الحجم. انظر أيضًا الأخطاء."
1102
1103 #. type: Plain text
1104 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1105 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1106 msgid ""
1107 "The B<pselect>() interface described in this page is implemented by glibc. "
1108 "The underlying Linux system call is named B<pselect6>(). This system call "
1109 "has somewhat different behavior from the glibc wrapper function."
1110 msgstr ""
1111 "واجهة B<pselect>() الموصوفة في هذه الصفحة منفذة بواسطة glibc. استدعاء نظام "
1112 "لينكس الأساسي يُسمى B<pselect6>(). هذا الاستدعاء له سلوك مختلف قليلاً عن دالة "
1113 "الغلاف glibc."
1114
1115 #. type: Plain text
1116 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1117 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1118 msgid ""
1119 "The Linux B<pselect6>() system call modifies its I<timeout> argument. "
1120 "However, the glibc wrapper function hides this behavior by using a local "
1121 "variable for the timeout argument that is passed to the system call. Thus, "
1122 "the glibc B<pselect>() function does not modify its I<timeout> argument; "
1123 "this is the behavior required by POSIX.1-2001."
1124 msgstr ""
1125 "يعدل استدعاء نظام لينكس B<pselect6>() وسيطته I<timeout>. لكن، دالة غلاف "
1126 "glibc تخفي هذا السلوك باستخدام متغير محلي لوسيطة timeout التي تُمرر لاستدعاء "
1127 "النظام. وبالتالي، دالة glibc B<pselect>() لا تعدل وسيطتها I<timeout>؛ هذا "
1128 "هو السلوك المطلوب بواسطة POSIX.1-2001."
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 final argument of the B<pselect6>() system call is not a I<sigset_t\\ "
1135 "*> pointer, but is instead a structure of the form:"
1136 msgstr ""
1137 "الوسيطة الأخيرة لاستدعاء النظام B<pselect6>() ليست مؤشر I<sigset_t\\ *>، بل "
1138 "هي بنية بالشكل:"
1139
1140 #. type: Plain text
1141 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1142 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1143 #, no-wrap
1144 msgid ""
1145 "struct {\n"
1146 " const kernel_sigset_t *ss; /* Pointer to signal set */\n"
1147 " size_t ss_len; /* Size (in bytes) of object\n"
1148 " pointed to by \\[aq]ss\\[aq] */\n"
1149 "};\n"
1150 msgstr ""
1151 "struct {\n"
1152 " const kernel_sigset_t *ss; /* Pointer to signal set */\n"
1153 " size_t ss_len; /* Size (in bytes) of object\n"
1154 " pointed to by \\[aq]ss\\[aq] */\n"
1155 "};\n"
1156
1157 #. type: Plain text
1158 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1159 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1160 msgid ""
1161 "This allows the system call to obtain both a pointer to the signal set and "
1162 "its size, while allowing for the fact that most architectures support a "
1163 "maximum of 6 arguments to a system call. See B<sigprocmask>(2) for a "
1164 "discussion of the difference between the kernel and libc notion of the "
1165 "signal set."
1166 msgstr ""
1167 "يسمح هذا لاستدعاء النظام بالحصول على كل من مؤشر لمجموعة الإشارات وحجمها، مع "
1168 "مراعاة حقيقة أن معظم البنى تدعم حدًا أقصى 6 وسائط لاستدعاء النظام. انظر "
1169 "B<sigprocmask>(2) لمناقشة الفرق بين مفهوم النواة وlibc لمجموعة الإشارات."
1170
1171 #. type: SS
1172 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1173 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1174 #, no-wrap
1175 msgid "Historical glibc details"
1176 msgstr "تفاصيل glibc التاريخية"
1177
1178 #. type: Plain text
1179 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1180 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1181 msgid ""
1182 "glibc 2.0 provided an incorrect version of B<pselect>() that did not take a "
1183 "I<sigmask> argument."
1184 msgstr ""
1185 "قدم glibc 2.0 نسخة غير صحيحة من B<pselect>() لم تأخذ وسيطة I<sigmask>."
1186
1187 #. type: Plain text
1188 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1189 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1190 msgid ""
1191 "From glibc 2.1 to glibc 2.2.1, one must define B<_GNU_SOURCE> in order to "
1192 "obtain the declaration of B<pselect>() from I<E<lt>sys/select.hE<gt>>."
1193 msgstr ""
1194 "من glibc 2.1 إلى glibc 2.2.1، يجب تعريف B<_GNU_SOURCE> للحصول على تعريف "
1195 "B<pselect>() من I<E<lt>sys/select.hE<gt>>."
1196
1197 #. type: SH
1198 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1199 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1200 #, no-wrap
1201 msgid "BUGS"
1202 msgstr "العلل"
1203
1204 #. type: Plain text
1205 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1206 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1207 msgid ""
1208 "POSIX allows an implementation to define an upper limit, advertised via the "
1209 "constant B<FD_SETSIZE>, on the range of file descriptors that can be "
1210 "specified in a file descriptor set. The Linux kernel imposes no fixed "
1211 "limit, but the glibc implementation makes I<fd_set> a fixed-size type, with "
1212 "B<FD_SETSIZE> defined as 1024, and the B<FD_*>() macros operating according "
1213 "to that limit. To monitor file descriptors greater than 1023, use "
1214 "B<poll>(2) or B<epoll>(7) instead."
1215 msgstr ""
1216 "يسمح POSIX للتطبيق بتعريف حد أعلى، معلن عنه عبر الثابت B<FD_SETSIZE>، على "
1217 "نطاق واصفات الملفات التي يمكن تحديدها في مجموعة واصفات ملفات. لا تفرض نواة "
1218 "لينكس حدًا ثابتًا، لكن تطبيق glibc يجعل I<fd_set> نوعًا ثابت الحجم، مع تعريف "
1219 "B<FD_SETSIZE> كـ 1024، وتعمل وحدات الماكرو B<FD_*>() وفقًا لذلك الحد. "
1220 "لمراقبة واصفات ملفات أكبر من 1023، استخدم B<poll>(2) أو B<epoll>(7) بدلاً "
1221 "من ذلك."
1222
1223 #. type: Plain text
1224 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1225 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1226 msgid ""
1227 "The implementation of the I<fd_set> arguments as value-result arguments is a "
1228 "design error that is avoided in B<poll>(2) and B<epoll>(7)."
1229 msgstr ""
1230 "تطبيق وسائط I<fd_set> كوسائط قيمة-نتيجة هو خطأ تصميمي يُتجنب في B<poll>(2) و "
1231 "B<epoll>(7)."
1232
1233 #. type: Plain text
1234 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1235 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1236 msgid ""
1237 "According to POSIX, B<select>() should check all specified file descriptors "
1238 "in the three file descriptor sets, up to the limit I<nfds-1>. However, the "
1239 "current implementation ignores any file descriptor in these sets that is "
1240 "greater than the maximum file descriptor number that the process currently "
1241 "has open. According to POSIX, any such file descriptor that is specified in "
1242 "one of the sets should result in the error B<EBADF>."
1243 msgstr ""
1244 "وفقًا لـ POSIX، يجب على B<select>() فحص جميع واصفات الملفات المحددة في "
1245 "المجموعات الثلاث لواصفات الملفات، حتى الحد I<nfds-1>. لكن، التطبيق الحالي "
1246 "يتجاهل أي واصف ملف في هذه المجموعات أكبر من رقم واصف الملف الأقصى الذي "
1247 "تمتلكه العملية مفتوحًا حاليًا. وفقًا لـ POSIX، أي واصف ملف كهذا محدد في إحدى "
1248 "المجموعات يجب أن يؤدي إلى الخطأ B<EBADF>."
1249
1250 #. type: Plain text
1251 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1252 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1253 msgid ""
1254 "Starting with glibc 2.1, glibc provided an emulation of B<pselect>() that "
1255 "was implemented using B<sigprocmask>(2) and B<select>(). This "
1256 "implementation remained vulnerable to the very race condition that "
1257 "B<pselect>() was designed to prevent. Modern versions of glibc use the "
1258 "(race-free) B<pselect>() system call on kernels where it is provided."
1259 msgstr ""
1260 "بدءًا من glibc 2.1، قدم glibc محاكاة لـ B<pselect>() منفذة باستخدام "
1261 "B<sigprocmask>(2) و B<select>(). ظل هذا التطبيق عرضة لنفس حالة السباق التي "
1262 "صُممت B<pselect>() لمنعها. تستخدم الإصدارات الحديثة من glibc استدعاء النظام "
1263 "(الخالي من السباق) B<pselect>() على النوى حيث يُوفر."
1264
1265 #. Stevens discusses a case where accept can block after select
1266 #. returns successfully because of an intervening RST from the client.
1267 #. Maybe the kernel should have returned EIO in such a situation?
1268 #. type: Plain text
1269 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1270 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1271 msgid ""
1272 "On Linux, B<select>() may report a socket file descriptor as \"ready for "
1273 "reading\", while nevertheless a subsequent read blocks. This could for "
1274 "example happen when data has arrived but upon examination has the wrong "
1275 "checksum and is discarded. There may be other circumstances in which a file "
1276 "descriptor is spuriously reported as ready. Thus it may be safer to use "
1277 "B<O_NONBLOCK> on sockets that should not block."
1278 msgstr ""
1279 "في لينكس، قد تُبلغ B<select>() عن واصف ملف مقبس كـ \"جاهز للقراءة\"، بينما "
1280 "مع ذلك تقرأ لاحقة تحظر. يمكن أن يحدث هذا مثلاً عندما تصل بيانات ولكن عند "
1281 "الفحص يكون المجموع الاختباري خاطئًا وتُتجاهل. قد تكون هناك ظروف أخرى يُبلغ "
1282 "فيها عن واصف ملف كجاهز بشكل زائف. لذا قد يكون من الأكثر أمانًا استخدام "
1283 "B<O_NONBLOCK> على مقابس لا يجب أن تحظر."
1284
1285 #. type: Plain text
1286 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1287 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1288 msgid ""
1289 "On Linux, B<select>() also modifies I<timeout> if the call is interrupted "
1290 "by a signal handler (i.e., the B<EINTR> error return). This is not "
1291 "permitted by POSIX.1. The Linux B<pselect>() system call has the same "
1292 "behavior, but the glibc wrapper hides this behavior by internally copying "
1293 "the I<timeout> to a local variable and passing that variable to the system "
1294 "call."
1295 msgstr ""
1296 "في لينكس، تعدل B<select>() أيضًا I<timeout> إذا قاطع معالج إشارة الاستدعاء "
1297 "(أي، إرجاع الخطأ B<EINTR>). هذا غير مسموح به بواسطة POSIX.1. استدعاء نظام "
1298 "لينكس B<pselect>() له نفس السلوك، لكن غلاف glibc يخفي هذا السلوك بنسخ "
1299 "I<timeout> داخليًا إلى متغير محلي وتمرير ذلك المتغير لاستدعاء النظام."
1300
1301 #. type: SH
1302 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1303 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1304 #, no-wrap
1305 msgid "EXAMPLES"
1306 msgstr "أمثلة"
1307
1308 #. type: Plain text
1309 #: archlinux debian-unstable mageia-cauldron opensuse-leap-16-1
1310 #: opensuse-tumbleweed
1311 #, no-wrap
1312 msgid ""
1313 "#include E<lt>stdio.hE<gt>\n"
1314 "#include E<lt>stdlib.hE<gt>\n"
1315 "#include E<lt>sys/select.hE<gt>\n"
1316 "#include E<lt>sys/time.hE<gt>\n"
1317 "\\&\n"
1318 "int\n"
1319 "main(void)\n"
1320 "{\n"
1321 " int retval;\n"
1322 " fd_set rfds;\n"
1323 " struct timeval tv;\n"
1324 "\\&\n"
1325 " /* Watch stdin (fd 0) to see when it has input. */\n"
1326 "\\&\n"
1327 " FD_ZERO(&rfds);\n"
1328 " FD_SET(0, &rfds);\n"
1329 "\\&\n"
1330 " /* Wait up to five seconds. */\n"
1331 "\\&\n"
1332 " tv.tv_sec = 5;\n"
1333 " tv.tv_usec = 0;\n"
1334 "\\&\n"
1335 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1336 " /* Don\\[aq]t rely on the value of tv now! */\n"
1337 "\\&\n"
1338 " if (retval == -1)\n"
1339 " perror(\"select()\");\n"
1340 " else if (retval)\n"
1341 " printf(\"Data is available now.\\[rs]n\");\n"
1342 " /* FD_ISSET(0, &rfds) will be true. */\n"
1343 " else\n"
1344 " printf(\"No data within five seconds.\\[rs]n\");\n"
1345 "\\&\n"
1346 " exit(EXIT_SUCCESS);\n"
1347 "}\n"
1348 msgstr ""
1349 "#include E<lt>stdio.hE<gt>\n"
1350 "#include E<lt>stdlib.hE<gt>\n"
1351 "#include E<lt>sys/select.hE<gt>\n"
1352 "#include E<lt>sys/time.hE<gt>\n"
1353 "\\&\n"
1354 "int\n"
1355 "main(void)\n"
1356 "{\n"
1357 " int retval;\n"
1358 " fd_set rfds;\n"
1359 " struct timeval tv;\n"
1360 "\\&\n"
1361 " /* Watch stdin (fd 0) to see when it has input. */\n"
1362 "\\&\n"
1363 " FD_ZERO(&rfds);\n"
1364 " FD_SET(0, &rfds);\n"
1365 "\\&\n"
1366 " /* Wait up to five seconds. */\n"
1367 "\\&\n"
1368 " tv.tv_sec = 5;\n"
1369 " tv.tv_usec = 0;\n"
1370 "\\&\n"
1371 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1372 " /* Don\\[aq]t rely on the value of tv now! */\n"
1373 "\\&\n"
1374 " if (retval == -1)\n"
1375 " perror(\"select()\");\n"
1376 " else if (retval)\n"
1377 " printf(\"Data is available now.\\[rs]n\");\n"
1378 " /* FD_ISSET(0, &rfds) will be true. */\n"
1379 " else\n"
1380 " printf(\"No data within five seconds.\\[rs]n\");\n"
1381 "\\&\n"
1382 " exit(EXIT_SUCCESS);\n"
1383 "}\n"
1384
1385 #. SRC END
1386 #. type: SH
1387 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1388 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1389 #, no-wrap
1390 msgid "SEE ALSO"
1391 msgstr "انظر أيضًا"
1392
1393 #. type: Plain text
1394 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1395 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1396 msgid ""
1397 "B<accept>(2), B<connect>(2), B<poll>(2), B<read>(2), B<recv>(2), "
1398 "B<restart_syscall>(2), B<send>(2), B<sigprocmask>(2), B<write>(2), "
1399 "B<timespec>(3), B<epoll>(7), B<time>(7)"
1400 msgstr ""
1401 "B<accept>(2), B<connect>(2), B<poll>(2), B<read>(2), B<recv>(2), "
1402 "B<restart_syscall>(2), B<send>(2), B<sigprocmask>(2), B<write>(2), "
1403 "B<timespec>(3), B<epoll>(7), B<time>(7)"
1404
1405 #. type: Plain text
1406 #: archlinux debian-trixie debian-unstable fedora-44 fedora-rawhide
1407 #: mageia-cauldron opensuse-leap-16-1 opensuse-tumbleweed
1408 msgid "For a tutorial with discussion and examples, see B<select_tut>(2)."
1409 msgstr "لدروس تعليمية مع مناقشة وأمثلة، انظر B<select_tut>(2)."
1410
1411 #. type: TH
1412 #: debian-trixie
1413 #, no-wrap
1414 msgid "2024-06-15"
1415 msgstr "15 يونيو 2024"
1416
1417 #. type: TH
1418 #: debian-trixie
1419 #, no-wrap
1420 msgid "Linux man-pages 6.9.1"
1421 msgstr "صفحات دليل لينكس 6.9.1"
1422
1423 #. type: Plain text
1424 #: debian-trixie
1425 msgid "Standard C library (I<libc>, I<-lc>)"
1426 msgstr "مكتبة سي المعيارية (I<libc>، I<-lc>)"
1427
1428 #. type: Plain text
1429 #: debian-trixie fedora-44 fedora-rawhide
1430 #, no-wrap
1431 msgid "B<typedef> /* ... */ B<fd_set;>\n"
1432 msgstr "B<typedef> /* ... */ B<fd_set;>\n"
1433
1434 #. type: Plain text
1435 #: debian-trixie fedora-44 fedora-rawhide
1436 #, no-wrap
1437 msgid ""
1438 "B<void FD_CLR(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1439 "B<int FD_ISSET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1440 "B<void FD_SET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1441 "B<void FD_ZERO(fd_set *>I<set>B<);>\n"
1442 msgstr ""
1443 "B<void FD_CLR(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1444 "B<int FD_ISSET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1445 "B<void FD_SET(int >I<fd>B<, fd_set *>I<set>B<);>\n"
1446 "B<void FD_ZERO(fd_set *>I<set>B<);>\n"
1447
1448 #. .P - it is rumored that:
1449 #. On BSD, when a timeout occurs, the file descriptor bits are not changed.
1450 #. - it is certainly true that:
1451 #. Linux follows SUSv2 and sets the bit masks to zero upon a timeout.
1452 #. type: Plain text
1453 #: debian-trixie fedora-44 fedora-rawhide
1454 msgid ""
1455 "On Linux, B<select>() modifies I<timeout> to reflect the amount of time not "
1456 "slept; most other implementations do not do this. (POSIX.1 permits either "
1457 "behavior.) This causes problems both when Linux code which reads I<timeout> "
1458 "is ported to other operating systems, and when code is ported to Linux that "
1459 "reuses a I<struct timeval> for multiple B<select>()s in a loop without "
1460 "reinitializing it. Consider I<timeout> to be undefined after B<select>() "
1461 "returns."
1462 msgstr ""
1463 "في لينكس، تعدل B<select>() I<timeout> لتعكس مقدار الوقت غير المُنام؛ معظم "
1464 "التطبيقات الأخرى لا تفعل هذا. (يسمح POSIX.1 بأي من السلوكين.) يسبب هذا "
1465 "مشاكل سواء عندما يُنقل كود لينكس الذي يقرأ I<timeout> إلى أنظمة تشغيل أخرى، "
1466 "وعندما يُنقل كود إلى لينكس يعيد استخدام I<struct timeval> لعدة B<select>()s "
1467 "في حلقة دون إعادة تهيئته. اعتبر I<timeout> غير معرف بعد عودة B<select>()."
1468
1469 #. type: Plain text
1470 #: debian-trixie fedora-44 fedora-rawhide
1471 msgid "POSIX.1-2008."
1472 msgstr "POSIX.1-2008."
1473
1474 #. type: Plain text
1475 #: debian-trixie
1476 #, no-wrap
1477 msgid ""
1478 "#include E<lt>stdio.hE<gt>\n"
1479 "#include E<lt>stdlib.hE<gt>\n"
1480 "#include E<lt>sys/select.hE<gt>\n"
1481 "\\&\n"
1482 "int\n"
1483 "main(void)\n"
1484 "{\n"
1485 " int retval;\n"
1486 " fd_set rfds;\n"
1487 " struct timeval tv;\n"
1488 "\\&\n"
1489 " /* Watch stdin (fd 0) to see when it has input. */\n"
1490 "\\&\n"
1491 " FD_ZERO(&rfds);\n"
1492 " FD_SET(0, &rfds);\n"
1493 "\\&\n"
1494 " /* Wait up to five seconds. */\n"
1495 "\\&\n"
1496 " tv.tv_sec = 5;\n"
1497 " tv.tv_usec = 0;\n"
1498 "\\&\n"
1499 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1500 " /* Don\\[aq]t rely on the value of tv now! */\n"
1501 "\\&\n"
1502 " if (retval == -1)\n"
1503 " perror(\"select()\");\n"
1504 " else if (retval)\n"
1505 " printf(\"Data is available now.\\[rs]n\");\n"
1506 " /* FD_ISSET(0, &rfds) will be true. */\n"
1507 " else\n"
1508 " printf(\"No data within five seconds.\\[rs]n\");\n"
1509 "\\&\n"
1510 " exit(EXIT_SUCCESS);\n"
1511 "}\n"
1512 msgstr ""
1513 "#include E<lt>stdio.hE<gt>\n"
1514 "#include E<lt>stdlib.hE<gt>\n"
1515 "#include E<lt>sys/select.hE<gt>\n"
1516 "\\&\n"
1517 "int\n"
1518 "main(void)\n"
1519 "{\n"
1520 " int retval;\n"
1521 " fd_set rfds;\n"
1522 " struct timeval tv;\n"
1523 "\\&\n"
1524 " /* Watch stdin (fd 0) to see when it has input. */\n"
1525 "\\&\n"
1526 " FD_ZERO(&rfds);\n"
1527 " FD_SET(0, &rfds);\n"
1528 "\\&\n"
1529 " /* Wait up to five seconds. */\n"
1530 "\\&\n"
1531 " tv.tv_sec = 5;\n"
1532 " tv.tv_usec = 0;\n"
1533 "\\&\n"
1534 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1535 " /* Don\\[aq]t rely on the value of tv now! */\n"
1536 "\\&\n"
1537 " if (retval == -1)\n"
1538 " perror(\"select()\");\n"
1539 " else if (retval)\n"
1540 " printf(\"Data is available now.\\[rs]n\");\n"
1541 " /* FD_ISSET(0, &rfds) will be true. */\n"
1542 " else\n"
1543 " printf(\"No data within five seconds.\\[rs]n\");\n"
1544 "\\&\n"
1545 " exit(EXIT_SUCCESS);\n"
1546 "}\n"
1547
1548 #. type: TH
1549 #: fedora-44 fedora-rawhide
1550 #, no-wrap
1551 msgid "2024-11-03"
1552 msgstr "3 نوفمبر 2024"
1553
1554 #. type: TH
1555 #: fedora-44 fedora-rawhide
1556 #, no-wrap
1557 msgid "Linux man-pages 6.13"
1558 msgstr "صفحات دليل لينكس 6.13"
1559
1560 #. type: Plain text
1561 #: fedora-44 fedora-rawhide
1562 #, no-wrap
1563 msgid ""
1564 "#include E<lt>stdio.hE<gt>\n"
1565 "#include E<lt>stdlib.hE<gt>\n"
1566 "#include E<lt>sys/select.hE<gt>\n"
1567 "#include E<lt>sys/time.hE<gt>\n"
1568 "\\&\n"
1569 "int\n"
1570 "main(void)\n"
1571 "{\n"
1572 " int retval;\n"
1573 " fd_set rfds;\n"
1574 " struct timeval tv;\n"
1575 "\\&\n"
1576 " /* Watch stdin (fd 0) to see when it has input. */\n"
1577 "\\&\n"
1578 " FD_ZERO(&rfds);\n"
1579 " FD_SET(0, &rfds);\n"
1580 "\\&\n"
1581 " /* Wait up to five seconds. */\n"
1582 "\\&\n"
1583 " tv.tv_sec = 5;\n"
1584 " tv.tv_usec = 0;\n"
1585 "\\&\n"
1586 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1587 " /* Don\\[aq]t rely on the value of tv now! */\n"
1588 "\\&\n"
1589 " if (retval == -1)\n"
1590 " perror(\"select()\");\n"
1591 " else if (retval)\n"
1592 " printf(\"Data is available now.\\[rs]n\");\n"
1593 " /* FD_ISSET(0, &rfds) will be true. */\n"
1594 " else\n"
1595 " printf(\"No data within five seconds.\\[rs]n\");\n"
1596 "\\&\n"
1597 " exit(EXIT_SUCCESS);\n"
1598 "}\n"
1599 msgstr ""
1600 "#include E<lt>stdio.hE<gt>\n"
1601 "#include E<lt>stdlib.hE<gt>\n"
1602 "#include E<lt>sys/select.hE<gt>\n"
1603 "#include E<lt>sys/time.hE<gt>\n"
1604 "\\&\n"
1605 "int\n"
1606 "main(void)\n"
1607 "{\n"
1608 " int retval;\n"
1609 " fd_set rfds;\n"
1610 " struct timeval tv;\n"
1611 "\\&\n"
1612 " /* Watch stdin (fd 0) to see when it has input. */\n"
1613 "\\&\n"
1614 " FD_ZERO(&rfds);\n"
1615 " FD_SET(0, &rfds);\n"
1616 "\\&\n"
1617 " /* Wait up to five seconds. */\n"
1618 "\\&\n"
1619 " tv.tv_sec = 5;\n"
1620 " tv.tv_usec = 0;\n"
1621 "\\&\n"
1622 " retval = select(1, &rfds, NULL, NULL, &tv);\n"
1623 " /* Don\\[aq]t rely on the value of tv now! */\n"
1624 "\\&\n"
1625 " if (retval == -1)\n"
1626 " perror(\"select()\");\n"
1627 " else if (retval)\n"
1628 " printf(\"Data is available now.\\[rs]n\");\n"
1629 " /* FD_ISSET(0, &rfds) will be true. */\n"
1630 " else\n"
1631 " printf(\"No data within five seconds.\\[rs]n\");\n"
1632 "\\&\n"
1633 " exit(EXIT_SUCCESS);\n"
1634 "}\n"
1635
1636 #. type: TH
1637 #: mageia-cauldron
1638 #, no-wrap
1639 msgid "Linux man-pages 6.17"
1640 msgstr "صفحات دليل لينكس 6.17"
1641
1642 #. type: TH
1643 #: opensuse-leap-16-1 opensuse-tumbleweed
1644 #, no-wrap
1645 msgid "Linux man-pages (unreleased)"
1646 msgstr "صفحات دليل لينكس (لم تصدر بعد)"