.\" -*- coding: UTF-8 -*- .\" Copyright 1993 David Metcalfe (david@prism.demon.co.uk) .\" .\" %%%LICENSE_START(VERBATIM) .\" Permission is granted to make and distribute verbatim copies of this .\" manual provided the copyright notice and this permission notice are .\" preserved on all copies. .\" .\" Permission is granted to copy and distribute modified versions of this .\" manual under the conditions for verbatim copying, provided that the .\" entire resulting derived work is distributed under the terms of a .\" permission notice identical to this one. .\" .\" Since the Linux kernel and libraries are constantly changing, this .\" manual page may be incorrect or out-of-date. The author(s) assume no .\" responsibility for errors or omissions, or for damages resulting from .\" the use of the information contained herein. The author(s) may not .\" have taken the same level of care in the production of this manual, .\" which is licensed free of charge, as they might when working .\" professionally. .\" .\" Formatted or processed versions of this manual, if unaccompanied by .\" the source, must acknowledge the copyright and authors of this work. .\" %%%LICENSE_END .\" .\" References consulted: .\" Linux libc source code .\" Lewine's _POSIX Programmer's Guide_ (O'Reilly & Associates, 1991) .\" 386BSD man pages .\" Modified Sat Jul 24 19:26:03 1993 by Rik Faith (faith@cs.unc.edu) .\"******************************************************************* .\" .\" This file was generated with po4a. Translate the source file. .\" .\"******************************************************************* .TH GETPROTOENT 3 "21 Diciembre 2020" GNU "Manual del Programador de Linux" .SH NOMBRE getprotoent, getprotobyname, getprotobynumber, setprotoent, endprotoent \- obtienen una entrada del fichero de protocolos .SH SINOPSIS .nf \fB#include \fP .PP \fBstruct protoent *getprotoent(void);\fP .PP \fBstruct protoent *getprotobyname(const char *\fP\fInombre\fP\fB);\fP .PP \fBstruct protoent *getprotobynumber(int \fP\fIproto\fP\fB);\fP .PP \fBvoid setprotoent(int \fP\fIdejaloabierto\fP\fB);\fP .PP \fBvoid endprotoent(void);\fP .fi .SH DESCRIPCIÓN La función \fBgetprotoent\fP() lee la siguiente línea de la base de datos de protocolos (consulte \fBprotocols\fP(5)) y devuelve una estructura \fIprotoent\fP que contiene los campos de que consta la línea. Si necesario, se abre una conexión a la base de datos. .PP La función \fBgetprotobyname()\fP devuelve una estructura \fIprotoent\fP para la línea de \fI/etc/protocols\fP que concuerde con el nombre de protocolo \fInombre\fP. Si necesario, se abre una conexión a la base de datos. .PP The \fBgetprotobynumber\fP() function returns a \fIprotoent\fP structure for the entry from the database that matches the protocol number \fInumber\fP. A connection is opened to the database if necessary. .PP The \fBsetprotoent\fP() function opens a connection to the database, and sets the next entry to the first entry. If \fIstayopen\fP is nonzero, then the connection to the database will not be closed between calls to one of the \fBgetproto*\fP() functions. .PP The \fBendprotoent\fP() function closes the connection to the database. .PP La estructura \fIprotoent\fP se define en \fI\fP así: .PP .in +4n .EX struct protoent { char *p_name; /* nombre oficial de protocolo */ char **p_aliases; /* lista de sinónimos */ int p_proto; /* número de protocolo */ } .EE .in .PP Los miembros de la estructura \fIprotoent\fP son: .TP \fIp_name\fP El nombre oficial del protocolo. .TP \fIp_aliases\fP Una lista terminada en NULL de nombres alternos para el protocolo. .TP \fIp_proto\fP El número del protocolo. .SH "VALOR DEVUELTO" The \fBgetprotoent\fP(), \fBgetprotobyname\fP(), and \fBgetprotobynumber\fP() functions return a pointer to a statically allocated \fIprotoent\fP structure, or a null pointer if an error occurs or the end of the file is reached. .SH ARCHIVOS .PD 0 .TP \fI/etc/protocols\fP fichero con los datos de protocolos .PD .SH ATRIBUTOS Para obtener una explicación de los términos usados en esta sección, véase \fBattributes\fP(7). .TS allbox; lbw18 lb lbw28 l l l. Interfaz Atributo Valor T{ \fBgetprotoent\fP() T} Seguridad del hilo T{ MT\-Unsafe race:protoent .br race:protoentbuf locale T} T{ \fBgetprotobyname\fP() T} Seguridad del hilo T{ MT\-Unsafe race:protobyname .br locale T} T{ \fBgetprotobynumber\fP() T} Seguridad del hilo T{ MT\-Unsafe race:protobynumber .br locale T} T{ \fBsetprotoent\fP(), .br \fBendprotoent\fP() T} Seguridad del hilo T{ MT\-Unsafe race:protoent .br locale T} .TE .sp 1 In the above table, \fIprotoent\fP in \fIrace:protoent\fP signifies that if any of the functions \fBsetprotoent\fP(), \fBgetprotoent\fP(), or \fBendprotoent\fP() are used in parallel in different threads of a program, then data races could occur. .SH "CONFORME A" POSIX.1\-2001, POSIX.1\-2008, 4.3BSD. .SH "VÉASE TAMBIÉN" \fBgetnetent\fP(3), \fBgetprotoent_r\fP(3), \fBgetservent\fP(3), \fBprotocols\fP(5) .SH COLOFÓN Esta página es parte de la versión 5.10 del proyecto Linux \fIman\-pages\fP. Puede encontrar una descripción del proyecto, información sobre cómo informar errores y la última versión de esta página en \%https://www.kernel.org/doc/man\-pages/. .PP .SH TRADUCCIÓN La traducción al español de esta página del manual fue creada por Gerardo Aburruzaga García y Marcos Fouces . .PP Esta traducción es documentación libre; lea la .UR https://www.gnu.org/licenses/gpl-3.0.html GNU General Public License Version 3 .UE o posterior con respecto a las condiciones de copyright. No existe NINGUNA RESPONSABILIDAD. .PP Si encuentra algún error en la traducción de esta página del manual, envíe un correo electrónico a .MT debian-l10n-spanish@lists.debian.org .ME .