source: rtems/cpukit/librpc/src/rpc/rtime.3 @ e5c8049

4.104.114.84.95
Last change on this file since e5c8049 was df49c60, checked in by Joel Sherrill <joel.sherrill@…>, on 06/12/00 at 15:00:15

Merged from 4.5.0-beta3a

  • Property mode set to 100644
File size: 1.1 KB
Line 
1.\" @(#)rtime.3n        2.1 88/08/08 4.0 RPCSRC; from 1.5 88/02/08 SMI
2.\" $FreeBSD: src/lib/libc/rpc/rtime.3,v 1.4 2000/03/02 09:13:48 sheldonh Exp $
3.\"
4.TH RTIME 3  "22 November 1987"
5.SH NAME
6rtime \- get remote time
7.SH SYNOPSIS
8.nf
9.B #include <sys/types.h>
10.B #include <sys/time.h>
11.B #include <netinet/in.h>
12.LP
13.B int rtime(addrp, timep, timeout)
14.B struct sockaddr_in \(**addrp;
15.B struct timeval \(**timep;
16.B struct timeval \(**timeout;
17.fi
18.SH DESCRIPTION
19.B rtime(\|)
20consults the Internet Time Server at the address pointed to by
21.I addrp
22and returns the remote time in the
23.B timeval
24struct pointed to by
25.IR timep .
26Normally, the
27.SM UDP
28protocol is used when consulting the Time Server.
29The
30.I timeout
31parameter specifies how long the
32routine should wait before giving
33up when waiting for a reply.  If
34.I timeout
35is specified as
36.SM NULL\s0,
37however, the routine will instead use
38.SM TCP
39and block until a reply is received from the time server.
40.LP
41The routine returns 0 if it is successful.
42Otherwise,
43it returns \-1 and
44.B errno
45is set to reflect the cause of the error.
46.SH "SEE ALSO"
47.BR timed (8c)
Note: See TracBrowser for help on using the repository browser.