⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 socket_equal.3ncs

📁 <B>Digital的Unix操作系统VAX 4.2源码</B>
💻 3NCS
字号:
.TH socket_equal 3ncs.SH Namesocket_equal \- compare two socket addresses.SH Syntax#include <idl/c/socket.h>boolean socket_$equal(\fIsockaddr1, s1length, sockaddr2, s2length, flags,\fP\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\fIstatus\fP).nfsocket_$addr_t *\fIsockaddr1\fP;unsigned long \fIs1length\fP;socket_$addr_t *\fIsockaddr2\fP;unsigned long \fIs2length\fP;unsigned long \fIflags\fP;status_$t *\fIstatus\fP;.fi.\".SH SYNOPSIS (PASCAL).\".DS.\"\fB%include '/usr/include/idl/pas/socket.ins.pas'\fR.\".\"\fBfunction socket_$equal(\fR.\"	\fBin \fIsockaddr1\fB: socket_$addr_t;\fR.\"	\fBin \fIs1length\fB: unsigned32;\fR.\"	\fBin \fIsockaddr2\fB: socket_$addr_t;\fR.\"	\fBin \fIs2length\fB: unsigned32;\fR.\"	\fBin \fIflags\fB: unsigned32;\fR.\"	\fBout \fIstatus\fB: status_$t): boolean;\fR.\".DE.SH Arguments.TP 20\fIsockaddr1\fRA socket address.  The socket address is the structure returned by either.PN rpc_use_familyor .PN rpc_use_family_wk ..TP 20\fIs1length\fRThe length, in bytes, of \fIsockaddr1\fR..TP 20\fIsockaddr2\fRA socket address.  The socket address is the structure returned by either.PN rpc_use_familyor .PN rpc_use_family_wk ..TP 20\fIs2length\fRThe length, in bytes, of \fIsockaddr2\fR..TP 20\fIflags\fRThe logical OR of values selected from the following:.RS.TP 20\fBsocket_$eq_hostid\fRIndicates that the host IDs are to be compared..TP 20\fBsocket_$eq_netaddr\fRIndicates that the network addresses are to be compared..TP 20\fBsocket_$eq_port\fRIndicates that the port numbers are to be compared..TP 20\fBsocket_$eq_network\fRIndicates that the network IDs are to be compared..RE.TP 20\fIstatus\fRThe completion status. If the completion status returned in.PN status\&.allis equal to.B status_$ok ,then the routine that supplied it was successful..SH DescriptionThe .PN socket_$equalroutine compares two socket addresses.The \fIflags\fR parameter determines which fields of the socket addresses are compared.The call returns `true' (not zero) if all of the fields compared areequal, `false' (zero) if not..NXR "Operations on Socket Addresses" "socket_equal".ig.SH External VariablesThis section describes external variables used in \fBsocket_$\fR routines..TP 20...SH ExamplesThe following routine compares the network and host IDs in thesocket addresses.I sockaddr1and.I sockaddr2:.EXif (socket_$equal (&sockaddr1, s1length, &sockaddr2, s2length,        socket_$eq_network | socket_$eq_hostid, &status))printf ("sockaddrs have equal network and host IDs\en");.EE.ig.SH Status CodesThis section lists status codes for errors returned by \fBsocket_$\fR routines....SH Files.PN /usr/include/idl/c/socket.h.br.PN /usr/include/idl/socket.idl.SH See Alsointro(3ncs)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -