summaryrefslogtreecommitdiffstats
path: root/po/fr/man2/poll.2.po
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--po/fr/man2/poll.2.po220
1 files changed, 203 insertions, 17 deletions
diff --git a/po/fr/man2/poll.2.po b/po/fr/man2/poll.2.po
index 6da444ff..609af495 100644
--- a/po/fr/man2/poll.2.po
+++ b/po/fr/man2/poll.2.po
@@ -18,9 +18,9 @@
# Jean-Philippe MENGUAL <jpmengual@debian.org>, 2021-2024.
msgid ""
msgstr ""
-"Project-Id-Version: manpages-l10n 4.21.0\n"
-"POT-Creation-Date: 2024-03-01 17:04+0100\n"
-"PO-Revision-Date: 2024-06-14 00:15+0100\n"
+"Project-Id-Version: manpages-l10n 4.22.0\n"
+"POT-Creation-Date: 2024-06-01 06:09+0200\n"
+"PO-Revision-Date: 2024-06-02 10:52+0200\n"
"Last-Translator: Jean-Philippe MENGUAL <jpmengual@debian.org>\n"
"Language-Team: French <debian-l10n-french@lists.debian.org>\n"
"Language: fr\n"
@@ -38,16 +38,16 @@ msgid "poll"
msgstr "poll"
#. type: TH
-#: archlinux fedora-40 fedora-rawhide mageia-cauldron
+#: archlinux debian-unstable opensuse-tumbleweed
#, no-wrap
-msgid "2023-10-31"
-msgstr "31 octobre 2023"
+msgid "2024-05-02"
+msgstr "2 mai 2024"
#. type: TH
-#: archlinux fedora-40 fedora-rawhide mageia-cauldron
+#: archlinux debian-unstable
#, no-wrap
-msgid "Linux man-pages 6.06"
-msgstr "Pages du manuel de Linux 6.06"
+msgid "Linux man-pages 6.8"
+msgstr "Pages du manuel de Linux 6.8"
#. type: SH
#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide
@@ -1131,8 +1131,7 @@ msgid "Program source"
msgstr "Source du programme"
#. type: Plain text
-#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron
-#: opensuse-tumbleweed
+#: archlinux debian-unstable opensuse-tumbleweed
#, no-wrap
msgid ""
"/* poll_input.c\n"
@@ -1143,6 +1142,7 @@ msgid ""
"#include E<lt>poll.hE<gt>\n"
"#include E<lt>stdio.hE<gt>\n"
"#include E<lt>stdlib.hE<gt>\n"
+"#include E<lt>sys/types.hE<gt>\n"
"#include E<lt>unistd.hE<gt>\n"
"\\&\n"
"#define errExit(msg) do { perror(msg); exit(EXIT_FAILURE); \\e\n"
@@ -1227,6 +1227,7 @@ msgstr ""
"#include E<lt>poll.hE<gt>\n"
"#include E<lt>stdio.hE<gt>\n"
"#include E<lt>stdlib.hE<gt>\n"
+"#include E<lt>sys/types.hE<gt>\n"
"#include E<lt>unistd.hE<gt>\n"
"\\&\n"
"#define errExit(msg) do { perror(msg); exit(EXIT_FAILURE); \\e\n"
@@ -1662,16 +1663,195 @@ msgstr ""
"}\n"
#. type: TH
-#: debian-unstable opensuse-tumbleweed
+#: fedora-40 fedora-rawhide mageia-cauldron
#, no-wrap
-msgid "2023-07-08"
-msgstr "8 juillet 2023"
+msgid "2023-10-31"
+msgstr "31 octobre 2023"
#. type: TH
-#: debian-unstable opensuse-tumbleweed
+#: fedora-40 mageia-cauldron
#, no-wrap
-msgid "Linux man-pages 6.05.01"
-msgstr "Pages du manuel de Linux 6.05.01"
+msgid "Linux man-pages 6.06"
+msgstr "Pages du manuel de Linux 6.06"
+
+#. type: Plain text
+#: fedora-40 fedora-rawhide mageia-cauldron
+#, no-wrap
+msgid ""
+"/* poll_input.c\n"
+"\\&\n"
+" Licensed under GNU General Public License v2 or later.\n"
+"*/\n"
+"#include E<lt>fcntl.hE<gt>\n"
+"#include E<lt>poll.hE<gt>\n"
+"#include E<lt>stdio.hE<gt>\n"
+"#include E<lt>stdlib.hE<gt>\n"
+"#include E<lt>unistd.hE<gt>\n"
+"\\&\n"
+"#define errExit(msg) do { perror(msg); exit(EXIT_FAILURE); \\e\n"
+" } while (0)\n"
+"\\&\n"
+"int\n"
+"main(int argc, char *argv[])\n"
+"{\n"
+" int ready;\n"
+" char buf[10];\n"
+" nfds_t num_open_fds, nfds;\n"
+" ssize_t s;\n"
+" struct pollfd *pfds;\n"
+"\\&\n"
+" if (argc E<lt> 2) {\n"
+" fprintf(stderr, \"Usage: %s file...\\en\", argv[0]);\n"
+" exit(EXIT_FAILURE);\n"
+" }\n"
+"\\&\n"
+" num_open_fds = nfds = argc - 1;\n"
+" pfds = calloc(nfds, sizeof(struct pollfd));\n"
+" if (pfds == NULL)\n"
+" errExit(\"malloc\");\n"
+"\\&\n"
+" /* Open each file on command line, and add it to \\[aq]pfds\\[aq] array. */\n"
+"\\&\n"
+" for (nfds_t j = 0; j E<lt> nfds; j++) {\n"
+" pfds[j].fd = open(argv[j + 1], O_RDONLY);\n"
+" if (pfds[j].fd == -1)\n"
+" errExit(\"open\");\n"
+"\\&\n"
+" printf(\"Opened \\e\"%s\\e\" on fd %d\\en\", argv[j + 1], pfds[j].fd);\n"
+"\\&\n"
+" pfds[j].events = POLLIN;\n"
+" }\n"
+"\\&\n"
+" /* Keep calling poll() as long as at least one file descriptor is\n"
+" open. */\n"
+"\\&\n"
+" while (num_open_fds E<gt> 0) {\n"
+" printf(\"About to poll()\\en\");\n"
+" ready = poll(pfds, nfds, -1);\n"
+" if (ready == -1)\n"
+" errExit(\"poll\");\n"
+"\\&\n"
+" printf(\"Ready: %d\\en\", ready);\n"
+"\\&\n"
+" /* Deal with array returned by poll(). */\n"
+"\\&\n"
+" for (nfds_t j = 0; j E<lt> nfds; j++) {\n"
+" if (pfds[j].revents != 0) {\n"
+" printf(\" fd=%d; events: %s%s%s\\en\", pfds[j].fd,\n"
+" (pfds[j].revents & POLLIN) ? \"POLLIN \" : \"\",\n"
+" (pfds[j].revents & POLLHUP) ? \"POLLHUP \" : \"\",\n"
+" (pfds[j].revents & POLLERR) ? \"POLLERR \" : \"\");\n"
+"\\&\n"
+" if (pfds[j].revents & POLLIN) {\n"
+" s = read(pfds[j].fd, buf, sizeof(buf));\n"
+" if (s == -1)\n"
+" errExit(\"read\");\n"
+" printf(\" read %zd bytes: %.*s\\en\",\n"
+" s, (int) s, buf);\n"
+" } else { /* POLLERR | POLLHUP */\n"
+" printf(\" closing fd %d\\en\", pfds[j].fd);\n"
+" if (close(pfds[j].fd) == -1)\n"
+" errExit(\"close\");\n"
+" num_open_fds--;\n"
+" }\n"
+" }\n"
+" }\n"
+" }\n"
+"\\&\n"
+" printf(\"All file descriptors closed; bye\\en\");\n"
+" exit(EXIT_SUCCESS);\n"
+"}\n"
+msgstr ""
+"/* poll_input.c\n"
+"\\&\n"
+" Sous licence GNU General Public v2 ou postérieure.\n"
+"*/\n"
+"#include E<lt>fcntl.hE<gt>\n"
+"#include E<lt>poll.hE<gt>\n"
+"#include E<lt>stdio.hE<gt>\n"
+"#include E<lt>stdlib.hE<gt>\n"
+"#include E<lt>unistd.hE<gt>\n"
+"\\&\n"
+"#define errExit(msg) do { perror(msg); exit(EXIT_FAILURE); \\e\n"
+" } while (0)\n"
+"\\&\n"
+"int\n"
+"main(int argc, char *argv[])\n"
+"{\n"
+" int ready;\n"
+" char buf[10];\n"
+" nfds_t num_open_fds, nfds;\n"
+" ssize_t s;\n"
+" struct pollfd *pfds;\n"
+"\\&\n"
+" if (argc E<lt> 2) {\n"
+" fprintf(stderr, \"Utilisation : %s file...\\en\", argv[0]);\n"
+" exit(EXIT_FAILURE);\n"
+" }\n"
+"\\&\n"
+" num_open_fds = nfds = argc - 1;\n"
+" pfds = calloc(nfds, sizeof(struct pollfd));\n"
+" if (pfds == NULL)\n"
+" errExit(\"malloc\");\n"
+"\\&\n"
+" /* Ouvrir chaque fichier de la ligne de commande et l'ajouter au tableau\n"
+" \\[aq]pfds\\[aq]. */\n"
+"\\&\n"
+" for (nfds_t j = 0; j E<lt> nfds; j++) {\n"
+" pfds[j].fd = open(argv[j + 1], O_RDONLY);\n"
+" if (pfds[j].fd == -1)\n"
+" errExit(\"open\");\n"
+"\\&\n"
+" printf(\"\"\\e\"%s\\e\" ouvert sur le fd %d\\en\", argv[j + 1], pfds[j].fd);\n"
+"\\&\n"
+" pfds[j].events = POLLIN;\n"
+" }\n"
+"\\&\n"
+" /* Conserver poll() au moins aussi longtemps qu'un descripteur de fichier\n"
+" est ouvert. */\n"
+"\\&\n"
+" while (num_open_fds E<gt> 0) {\n"
+" printf(\"Préparation pour poll()\\en\");\n"
+" ready = poll(pfds, nfds, -1);\n"
+" if (ready == -1)\n"
+" errExit(\"poll\");\n"
+"\\&\n"
+" printf(\"Prêt: %d\\en\", ready);\n"
+"\\&\n"
+" /* Gérer le tableau renvoyé par poll(). */\n"
+"\\&\n"
+" for (nfds_t j = 0; j E<lt> nfds; j++) {\n"
+" if (pfds[j].revents != 0) {\n"
+" printf(\" fd=%d; événements : %s%s%s\\en\", pfds[j].fd,\n"
+" (pfds[j].revents & POLLIN) ? \"POLLIN \" : \"\",\n"
+" (pfds[j].revents & POLLHUP) ? \"POLLHUP \" : \"\",\n"
+" (pfds[j].revents & POLLERR) ? \"POLLERR \" : \"\");\n"
+"\\&\n"
+" if (pfds[j].revents & POLLIN) {\n"
+" s = read(pfds[j].fd, buf, sizeof(buf));\n"
+" if (s == -1)\n"
+" errExit(\"read\");\n"
+" printf(\" lecture de %zd octets : %.*s\\en\",\n"
+" s, (int) s, buf);\n"
+" } else { /* POLLERR | POLLHUP */\n"
+" printf(\" fermeture du fd %d\\en\", pfds[j].fd);\n"
+" if (close(pfds[j].fd) == -1)\n"
+" errExit(\"close\");\n"
+" num_open_fds--;\n"
+" }\n"
+" }\n"
+" }\n"
+" }\n"
+"\\&\n"
+" printf(\"Tous les descripteurs de fichier sont fermés ; au revoir\\en\");\n"
+" exit(EXIT_SUCCESS);\n"
+"}\n"
+
+#. type: TH
+#: fedora-rawhide
+#, no-wrap
+msgid "Linux man-pages 6.7"
+msgstr "Pages du manuel de Linux 6.7"
#. type: TH
#: opensuse-leap-15-6
@@ -1684,3 +1864,9 @@ msgstr "30 mars 2023"
#, no-wrap
msgid "Linux man-pages 6.04"
msgstr "Pages du manuel de Linux 6.04"
+
+#. type: TH
+#: opensuse-tumbleweed
+#, no-wrap
+msgid "Linux man-pages (unreleased)"
+msgstr "Pages du manuel de Linux (non publiées)"