diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 19:43:11 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-15 19:43:11 +0000 |
commit | fc22b3d6507c6745911b9dfcc68f1e665ae13dbc (patch) | |
tree | ce1e3bce06471410239a6f41282e328770aa404a /po/ru/man2/bind.2.po | |
parent | Initial commit. (diff) | |
download | manpages-l10n-fc22b3d6507c6745911b9dfcc68f1e665ae13dbc.tar.xz manpages-l10n-fc22b3d6507c6745911b9dfcc68f1e665ae13dbc.zip |
Adding upstream version 4.22.0.upstream/4.22.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'po/ru/man2/bind.2.po')
-rw-r--r-- | po/ru/man2/bind.2.po | 823 |
1 files changed, 823 insertions, 0 deletions
diff --git a/po/ru/man2/bind.2.po b/po/ru/man2/bind.2.po new file mode 100644 index 00000000..2ea77827 --- /dev/null +++ b/po/ru/man2/bind.2.po @@ -0,0 +1,823 @@ +# Russian translation of manpages +# This file is distributed under the same license as the manpages-l10n package. +# Copyright © of this file: +# Artyom Kunyov <artkun@guitarplayer.ru>, 2012. +# Azamat Hackimov <azamat.hackimov@gmail.com>, 2012. +# Dmitriy Ovchinnikov <dmitriyxt5@gmail.com>, 2012. +# Dmitry Bolkhovskikh <d20052005@yandex.ru>, 2017. +# ITriskTI <ITriskTI@gmail.com>, 2012. +# Yuri Kozlov <yuray@komyakino.ru>, 2011-2019. +# Иван Павлов <pavia00@gmail.com>, 2017. +msgid "" +msgstr "" +"Project-Id-Version: manpages-l10n\n" +"POT-Creation-Date: 2024-03-01 16:53+0100\n" +"PO-Revision-Date: 2019-08-27 07:22+0000\n" +"Last-Translator: Yuri Kozlov <yuray@komyakino.ru>\n" +"Language-Team: Russian <man-pages-ru-talks@lists.sourceforge.net>\n" +"Language: ru\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Plural-Forms: nplurals=4; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && " +"n%10<=4 && (n%100<12 || n%100>14) ? 1 : n%10==0 || (n%10>=5 && n%10<=9) || " +"(n%100>=11 && n%100<=14)? 2 : 3);\n" + +#. type: TH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "bind" +msgstr "bind" + +#. type: TH +#: archlinux fedora-40 fedora-rawhide mageia-cauldron +#, no-wrap +msgid "2023-10-31" +msgstr "31 октября 2023 г." + +#. type: TH +#: archlinux fedora-40 fedora-rawhide mageia-cauldron +#, no-wrap +msgid "Linux man-pages 6.06" +msgstr "Linux man-pages 6.06" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "NAME" +msgstr "ИМЯ" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "bind - bind a name to a socket" +msgstr "bind - привязывает имя к сокету" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "LIBRARY" +msgstr "" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "Standard C library (I<libc>, I<-lc>)" +msgstr "" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "SYNOPSIS" +msgstr "СИНТАКСИС" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<#include E<lt>sys/socket.hE<gt>>\n" +msgstr "B<#include E<lt>sys/socket.hE<gt>>\n" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "" +"B<int bind(int >I<sockfd>B<, const struct sockaddr *>I<addr>B<,>\n" +"B< socklen_t >I<addrlen>B<);>\n" +msgstr "" +"B<int bind(int >I<sockfd>B<, const struct sockaddr *>I<addr>B<,>\n" +"B< socklen_t >I<addrlen>B<);>\n" + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "DESCRIPTION" +msgstr "ОПИСАНИЕ" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, fuzzy +#| msgid "" +#| "When a socket is created with B<socket>(2), it exists in a name space " +#| "(address family) but has no address assigned to it. B<bind>() assigns " +#| "the address specified by I<addr> to the socket referred to by the file " +#| "descriptor I<sockfd>. I<addrlen> specifies the size, in bytes, of the " +#| "address structure pointed to by I<addr>. Traditionally, this operation " +#| "is called \\(lqassigning a name to a socket\\(rq." +msgid "" +"When a socket is created with B<socket>(2), it exists in a name space " +"(address family) but has no address assigned to it. B<bind>() assigns the " +"address specified by I<addr> to the socket referred to by the file " +"descriptor I<sockfd>. I<addrlen> specifies the size, in bytes, of the " +"address structure pointed to by I<addr>. Traditionally, this operation is " +"called \\[lq]assigning a name to a socket\\[rq]." +msgstr "" +"После создания с помощью B<socket>(2), сокет появляется в адресном " +"пространстве (семействе адресов), но без назначенного адреса. B<bind>() " +"назначает адрес, заданный в I<addr>, сокету, указываемому дескриптором файла " +"I<sockfd>. В аргументе I<addrlen> задаётся размер структуры адреса (в " +"байтах), на которую указывает I<addr>. В силу традиции, эта операция " +"называется «присваивание сокету имени»." + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"It is normally necessary to assign a local address using B<bind>() before a " +"B<SOCK_STREAM> socket may receive connections (see B<accept>(2))." +msgstr "" +"Обычно, сокету типа B<SOCK_STREAM> нужно назначить локальный адрес с помощью " +"B<bind>() до того, как он сможет принимать соединения (см. B<accept>(2))." + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The rules used in name binding vary between address families. Consult the " +"manual entries in Section 7 for detailed information. For B<AF_INET>, see " +"B<ip>(7); for B<AF_INET6>, see B<ipv6>(7); for B<AF_UNIX>, see B<unix>(7); " +"for B<AF_APPLETALK>, see B<ddp>(7); for B<AF_PACKET>, see B<packet>(7); for " +"B<AF_X25>, see B<x25>(7); and for B<AF_NETLINK>, see B<netlink>(7)." +msgstr "" +"Правила, используемые при привязке имён, отличаются в разных семействах " +"адресов. Подробности см. в соответствующем справочных страницах в разделе 7. " +"Описание B<AF_INET> находится в B<ip>(7), B<AF_INET6> в B<ipv6>(7), " +"B<AF_UNIX> в B<unix>(7), B<AF_APPLETALK> в B<ddp>(7), B<AF_PACKET> в " +"B<packet>(7), B<AF_X25> в B<x25>(7), а B<AF_NETLINK> в B<netlink>(7)." + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The actual structure passed for the I<addr> argument will depend on the " +"address family. The I<sockaddr> structure is defined as something like:" +msgstr "" +"Реальная структура, передаваемая через I<addr>, зависит от семейства " +"адресов. Структура I<sockaddr> определяется так:" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "" +"struct sockaddr {\n" +" sa_family_t sa_family;\n" +" char sa_data[14];\n" +"}\n" +msgstr "" +"struct sockaddr {\n" +" sa_family_t sa_family;\n" +" char sa_data[14];\n" +"}\n" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The only purpose of this structure is to cast the structure pointer passed " +"in I<addr> in order to avoid compiler warnings. See EXAMPLES below." +msgstr "" +"Единственным смыслом этой структуры является преобразование указателя " +"структуры, передаваемого в I<addr>, чтобы избежать предупреждений " +"компилятора. См. ПРИМЕРЫ ниже." + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "RETURN VALUE" +msgstr "ВОЗВРАЩАЕМОЕ ЗНАЧЕНИЕ" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, fuzzy +#| msgid "" +#| "On success, zero is returned. On error, -1 is returned, and I<errno> is " +#| "set appropriately." +msgid "" +"On success, zero is returned. On error, -1 is returned, and I<errno> is set " +"to indicate the error." +msgstr "" +"При успешном выполнении возвращается 0. В случае ошибки возвращается -1, а " +"I<errno> устанавливается в соответствующее значение." + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "ERRORS" +msgstr "ОШИБКИ" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EACCES>" +msgstr "B<EACCES>" + +#. e.g., privileged port in AF_INET domain +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "The address is protected, and the user is not the superuser." +msgstr "Адрес защищён, или пользователь не является суперпользователем." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EADDRINUSE>" +msgstr "B<EADDRINUSE>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "The given address is already in use." +msgstr "Указанный адрес уже используется." + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"(Internet domain sockets) The port number was specified as zero in the " +"socket address structure, but, upon attempting to bind to an ephemeral port, " +"it was determined that all port numbers in the ephemeral port range are " +"currently in use. See the discussion of I</proc/sys/net/ipv4/" +"ip_local_port_range> B<ip>(7)." +msgstr "" +"(доменные сокеты Интернета) В структуре адреса сокета указан номер порта " +"равный нулю, но при попытке привязаться к эфемеридному порту, было " +"определено, что все номера в диапазоне эфемеридных портов уже используются. " +"Смотрите обсуждение I</proc/sys/net/ipv4/ip_local_port_range> в B<ip>(7)." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EBADF>" +msgstr "B<EBADF>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "I<sockfd> is not a valid file descriptor." +msgstr "Значение I<sockfd> не является правильным файловым дескриптором." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EINVAL>" +msgstr "B<EINVAL>" + +#. This may change in the future: see +#. .I linux/unix/sock.c for details. +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "The socket is already bound to an address." +msgstr "Сокет уже привязан к адресу." + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"I<addrlen> is wrong, or I<addr> is not a valid address for this socket's " +"domain." +msgstr "" +"Некорректное значение I<addrlen>, или в I<addr> указан некорректный адрес " +"для этого доменного сокета." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<ENOTSOCK>" +msgstr "B<ENOTSOCK>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "The file descriptor I<sockfd> does not refer to a socket." +msgstr "Файловый дескриптор I<sockfd> указывает не на каталог." + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "The following errors are specific to UNIX domain (B<AF_UNIX>) sockets:" +msgstr "Следующие ошибки только для сокетов домена UNIX (B<AF_UNIX>):" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"Search permission is denied on a component of the path prefix. (See also " +"B<path_resolution>(7).)" +msgstr "" +"Поиск запрещён из-за одного из частей префикса пути (См. также " +"B<path_resolution>(7).)" + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EADDRNOTAVAIL>" +msgstr "B<EADDRNOTAVAIL>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"A nonexistent interface was requested or the requested address was not local." +msgstr "" +"Запрошен несуществующий интерфейс или запрашиваемый адрес не является " +"локальным." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EFAULT>" +msgstr "B<EFAULT>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "I<addr> points outside the user's accessible address space." +msgstr "I<addr> указывает вне адресного пространства, доступного пользователю." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<ELOOP>" +msgstr "B<ELOOP>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "Too many symbolic links were encountered in resolving I<addr>." +msgstr "" +"При определении I<addr> превышено количество переходов по символьной ссылке." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<ENAMETOOLONG>" +msgstr "B<ENAMETOOLONG>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "I<addr> is too long." +msgstr "Аргумент I<addr> слишком большой." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<ENOENT>" +msgstr "B<ENOENT>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"A component in the directory prefix of the socket pathname does not exist." +msgstr "Компонент из каталожного префикса пути сокета не существует." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<ENOMEM>" +msgstr "B<ENOMEM>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "Insufficient kernel memory was available." +msgstr "Недостаточное количество памяти ядра." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<ENOTDIR>" +msgstr "B<ENOTDIR>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "A component of the path prefix is not a directory." +msgstr "Компонент в префиксе пути не является каталогом." + +#. type: TP +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "B<EROFS>" +msgstr "B<EROFS>" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "The socket inode would reside on a read-only filesystem." +msgstr "" +"Попытка создания inode сокета на файловой системе, доступной только для " +"чтения." + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "STANDARDS" +msgstr "СТАНДАРТЫ" + +#. type: Plain text +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-leap-15-6 opensuse-tumbleweed +msgid "POSIX.1-2008." +msgstr "POSIX.1-2008." + +#. type: SH +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "HISTORY" +msgstr "ИСТОРИЯ" + +#. SVr4 documents an additional +#. .B ENOSR +#. general error condition, and +#. additional +#. .B EIO +#. and +#. .B EISDIR +#. UNIX-domain error conditions. +#. type: Plain text +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-leap-15-6 opensuse-tumbleweed +#, fuzzy +#| msgid "" +#| "POSIX.1-2001, POSIX.1-2008, SVr4, 4.4BSD (B<bind>() first appeared in " +#| "4.2BSD)." +msgid "POSIX.1-2001, SVr4, 4.4BSD (B<bind>() first appeared in 4.2BSD)." +msgstr "" +"POSIX.1-2001, POSIX.1-2008, SVr4, 4.4BSD, (B<bind>() впервые появился в " +"4.2BSD)." + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "BUGS" +msgstr "ДЕФЕКТЫ" + +#. FIXME Document transparent proxy options +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "The transparent proxy options are not described." +msgstr "Не описываются возможности, связанные с работой прозрачных прокси." + +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "EXAMPLES" +msgstr "ПРИМЕРЫ" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"An example of the use of B<bind>() with Internet domain sockets can be " +"found in B<getaddrinfo>(3)." +msgstr "" +"Пример использования B<bind>() с сокетами домена Internet можно найти в " +"B<getaddrinfo>(3)." + +#. listen.7 refers to this example. +#. accept.7 refers to this example. +#. unix.7 refers to this example. +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"The following example shows how to bind a stream socket in the UNIX " +"(B<AF_UNIX>) domain, and accept connections:" +msgstr "" +"Следующий пример показывает как привязать потоковый сокет к домену UNIX " +"(B<AF_UNIX>) и принимать соединения:" + +#. type: Plain text +#: archlinux debian-unstable fedora-40 fedora-rawhide mageia-cauldron +#: opensuse-tumbleweed +#, no-wrap +msgid "" +"#include E<lt>stdio.hE<gt>\n" +"#include E<lt>stdlib.hE<gt>\n" +"#include E<lt>string.hE<gt>\n" +"#include E<lt>sys/socket.hE<gt>\n" +"#include E<lt>sys/un.hE<gt>\n" +"#include E<lt>unistd.hE<gt>\n" +"\\&\n" +"#define MY_SOCK_PATH \"/somepath\"\n" +"#define LISTEN_BACKLOG 50\n" +"\\&\n" +"#define handle_error(msg) \\e\n" +" do { perror(msg); exit(EXIT_FAILURE); } while (0)\n" +"\\&\n" +"int\n" +"main(void)\n" +"{\n" +" int sfd, cfd;\n" +" socklen_t peer_addr_size;\n" +" struct sockaddr_un my_addr, peer_addr;\n" +"\\&\n" +" sfd = socket(AF_UNIX, SOCK_STREAM, 0);\n" +" if (sfd == -1)\n" +" handle_error(\"socket\");\n" +"\\&\n" +" memset(&my_addr, 0, sizeof(my_addr));\n" +" my_addr.sun_family = AF_UNIX;\n" +" strncpy(my_addr.sun_path, MY_SOCK_PATH,\n" +" sizeof(my_addr.sun_path) - 1);\n" +"\\&\n" +" if (bind(sfd, (struct sockaddr *) &my_addr,\n" +" sizeof(my_addr)) == -1)\n" +" handle_error(\"bind\");\n" +"\\&\n" +" if (listen(sfd, LISTEN_BACKLOG) == -1)\n" +" handle_error(\"listen\");\n" +"\\&\n" +" /* Now we can accept incoming connections one\n" +" at a time using accept(2). */\n" +"\\&\n" +" peer_addr_size = sizeof(peer_addr);\n" +" cfd = accept(sfd, (struct sockaddr *) &peer_addr,\n" +" &peer_addr_size);\n" +" if (cfd == -1)\n" +" handle_error(\"accept\");\n" +"\\&\n" +" /* Code to deal with incoming connection(s)... */\n" +"\\&\n" +" if (close(sfd) == -1)\n" +" handle_error(\"close\");\n" +"\\&\n" +" if (unlink(MY_SOCK_PATH) == -1)\n" +" handle_error(\"unlink\");\n" +"}\n" +msgstr "" + +#. SRC END +#. type: SH +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +#, no-wrap +msgid "SEE ALSO" +msgstr "СМ. ТАКЖЕ" + +#. type: Plain text +#: archlinux debian-bookworm debian-unstable fedora-40 fedora-rawhide +#: mageia-cauldron opensuse-leap-15-6 opensuse-tumbleweed +msgid "" +"B<accept>(2), B<connect>(2), B<getsockname>(2), B<listen>(2), B<socket>(2), " +"B<getaddrinfo>(3), B<getifaddrs>(3), B<ip>(7), B<ipv6>(7), " +"B<path_resolution>(7), B<socket>(7), B<unix>(7)" +msgstr "" +"B<accept>(2), B<connect>(2), B<getsockname>(2), B<listen>(2), B<socket>(2), " +"B<getaddrinfo>(3), B<getifaddrs>(3), B<ip>(7), B<ipv6>(7), " +"B<path_resolution>(7), B<socket>(7), B<unix>(7)" + +#. type: TH +#: debian-bookworm +#, no-wrap +msgid "2023-02-05" +msgstr "5 февраля 2023 г." + +#. type: TH +#: debian-bookworm +#, no-wrap +msgid "Linux man-pages 6.03" +msgstr "Linux man-pages 6.03" + +#. SVr4 documents an additional +#. .B ENOSR +#. general error condition, and +#. additional +#. .B EIO +#. and +#. .B EISDIR +#. UNIX-domain error conditions. +#. type: Plain text +#: debian-bookworm +msgid "" +"POSIX.1-2001, POSIX.1-2008, SVr4, 4.4BSD (B<bind>() first appeared in " +"4.2BSD)." +msgstr "" +"POSIX.1-2001, POSIX.1-2008, SVr4, 4.4BSD, (B<bind>() впервые появился в " +"4.2BSD)." + +#. type: SH +#: debian-bookworm +#, no-wrap +msgid "NOTES" +msgstr "ЗАМЕЧАНИЯ" + +#. type: Plain text +#: debian-bookworm +msgid "For background on the I<socklen_t> type, see B<accept>(2)." +msgstr "Описание типа I<socklen_t> смотрите в B<accept>(2)." + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +"#include E<lt>stdio.hE<gt>\n" +"#include E<lt>stdlib.hE<gt>\n" +"#include E<lt>string.hE<gt>\n" +"#include E<lt>sys/socket.hE<gt>\n" +"#include E<lt>sys/un.hE<gt>\n" +"#include E<lt>unistd.hE<gt>\n" +msgstr "" +"#include E<lt>stdio.hE<gt>\n" +"#include E<lt>stdlib.hE<gt>\n" +"#include E<lt>string.hE<gt>\n" +"#include E<lt>sys/socket.hE<gt>\n" +"#include E<lt>sys/un.hE<gt>\n" +"#include E<lt>unistd.hE<gt>\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +"#define MY_SOCK_PATH \"/somepath\"\n" +"#define LISTEN_BACKLOG 50\n" +msgstr "" +"#define MY_SOCK_PATH \"/somepath\"\n" +"#define LISTEN_BACKLOG 50\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +"#define handle_error(msg) \\e\n" +" do { perror(msg); exit(EXIT_FAILURE); } while (0)\n" +msgstr "" +"#define handle_error(msg) \\e\n" +" do { perror(msg); exit(EXIT_FAILURE); } while (0)\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +"int\n" +"main(void)\n" +"{\n" +" int sfd, cfd;\n" +" socklen_t peer_addr_size;\n" +" struct sockaddr_un my_addr, peer_addr;\n" +msgstr "" +"int\n" +"main(void)\n" +"{\n" +" int sfd, cfd;\n" +" socklen_t peer_addr_size;\n" +" struct sockaddr_un my_addr, peer_addr;\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" sfd = socket(AF_UNIX, SOCK_STREAM, 0);\n" +" if (sfd == -1)\n" +" handle_error(\"socket\");\n" +msgstr "" +" sfd = socket(AF_UNIX, SOCK_STREAM, 0);\n" +" if (sfd == -1)\n" +" handle_error(\"socket\");\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" memset(&my_addr, 0, sizeof(my_addr));\n" +" my_addr.sun_family = AF_UNIX;\n" +" strncpy(my_addr.sun_path, MY_SOCK_PATH,\n" +" sizeof(my_addr.sun_path) - 1);\n" +msgstr "" +" memset(&my_addr, 0, sizeof(my_addr));\n" +" my_addr.sun_family = AF_UNIX;\n" +" strncpy(my_addr.sun_path, MY_SOCK_PATH,\n" +" sizeof(my_addr.sun_path) - 1);\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" if (bind(sfd, (struct sockaddr *) &my_addr,\n" +" sizeof(my_addr)) == -1)\n" +" handle_error(\"bind\");\n" +msgstr "" +" if (bind(sfd, (struct sockaddr *) &my_addr,\n" +" sizeof(my_addr)) == -1)\n" +" handle_error(\"bind\");\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" if (listen(sfd, LISTEN_BACKLOG) == -1)\n" +" handle_error(\"listen\");\n" +msgstr "" +" if (listen(sfd, LISTEN_BACKLOG) == -1)\n" +" handle_error(\"listen\");\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" /* Now we can accept incoming connections one\n" +" at a time using accept(2). */\n" +msgstr "" +" /* Теперь мы можем принимать входящие соединения по одному\n" +" с помощью accept(2). */\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" peer_addr_size = sizeof(peer_addr);\n" +" cfd = accept(sfd, (struct sockaddr *) &peer_addr,\n" +" &peer_addr_size);\n" +" if (cfd == -1)\n" +" handle_error(\"accept\");\n" +msgstr "" +" peer_addr_size = sizeof(peer_addr);\n" +" cfd = accept(sfd, (struct sockaddr *) &peer_addr,\n" +" &peer_addr_size);\n" +" if (cfd == -1)\n" +" handle_error(\"accept\");\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid " /* Code to deal with incoming connection(s)... */\n" +msgstr " /* Код обработки входящего соединения(й)... */\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" if (close(sfd) == -1)\n" +" handle_error(\"close\");\n" +msgstr "" +" if (close(sfd) == -1)\n" +" handle_error(\"close\");\n" + +#. type: Plain text +#: debian-bookworm opensuse-leap-15-6 +#, no-wrap +msgid "" +" if (unlink(MY_SOCK_PATH) == -1)\n" +" handle_error(\"unlink\");\n" +"}\n" +msgstr "" +" if (unlink(MY_SOCK_PATH) == -1)\n" +" handle_error(\"unlink\");\n" +"}\n" + +#. type: TH +#: debian-unstable opensuse-tumbleweed +#, no-wrap +msgid "2023-05-03" +msgstr "3 мая 2023 г." + +#. type: TH +#: debian-unstable opensuse-tumbleweed +#, no-wrap +msgid "Linux man-pages 6.05.01" +msgstr "Linux man-pages 6.05.01" + +#. type: TH +#: opensuse-leap-15-6 +#, no-wrap +msgid "2023-03-30" +msgstr "30 марта 2023 г." + +#. type: TH +#: opensuse-leap-15-6 +#, no-wrap +msgid "Linux man-pages 6.04" +msgstr "Linux man-pages 6.04" |