OSDN Git Service

41aa63ba11cf0ead5129b490cea8d573eaa9448e
[linuxjm/LDP_man-pages.git] / original / man3 / getrpcport.3
1 .\" This page was taken from the 4.4BSD-Lite CDROM (BSD license)
2 .\"
3 .\" %%%LICENSE_START(BSD_ONELINE_CDROM)
4 .\" This page was taken from the 4.4BSD-Lite CDROM (BSD license)
5 .\" %%%LICENSE_END
6 .\"
7 .\" @(#)getrpcport.3r   2.2 88/08/02 4.0 RPCSRC; from 1.12 88/02/26 SMI
8 .TH GETRPCPORT 3 2007-12-23 "" "Linux Programmer's Manual"
9 .SH NAME
10 getrpcport \- get RPC port number
11 .SH SYNOPSIS
12 .nf
13 .BI "int getrpcport(char *" host ", int " prognum ", int " versnum \
14 ", int " proto );
15 .fi
16 .SH DESCRIPTION
17 .BR getrpcport ()
18 returns the port number for version
19 .I versnum
20 of the RPC program
21 .I prognum
22 running on
23 .I host
24 and using protocol
25 .IR proto .
26 It returns 0 if it cannot contact the portmapper, or if
27 .I prognum
28 is not registered.
29 If
30 .I prognum
31 is registered but not with version
32 .IR versnum ,
33 it will still return a port number (for some version of the program)
34 indicating that the program is indeed registered.
35 The version mismatch will be detected upon the first call to the service.
36 .SH CONFORMING TO
37 Not in POSIX.1-2001.
38 Present on the BSDs, Solaris, and many other systems.
39 .SH COLOPHON
40 This page is part of release 3.67 of the Linux
41 .I man-pages
42 project.
43 A description of the project,
44 information about reporting bugs,
45 and the latest version of this page,
46 can be found at
47 \%http://www.kernel.org/doc/man\-pages/.