Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ ntp_gettime(2) — SunOS 5.6

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

xntpd(1M)

ntp_adjtime(2)

ntp_gettime(2)

NAME

ntp_gettime − get local clock values

SYNOPSIS

#include <sys/timex.h>
int ntp_gettime(struct ntptimeval ∗tptr )

DESCRIPTION

ntp_gettime reads the local clock value and dispersion, returning the information in tptr. 

struct ntptimeval {
        struct timeval time;    /∗ current time (ro) ∗/
        int32_t maxerror;          /∗ maximum error (us) (ro) ∗/
        int32_t esterror;          /∗ estimated error (us) (ro) ∗/
  };

RETURN VALUES

ntp_gettime returns:

0 On success

-1 On failure

ntp_gettime sets errno to the following:

EFAULT if tptr points to an invalid address

SEE ALSO

xntpd(1M), ntp_adjtime(2)

SunOS 5.6  —  Last change: 28 Jan 1997

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026