Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ settimeofday(2) — DG/UX 4.00

Media Vault

Software Library

Restoration Projects

Artifacts Sought



                                                          settimeofday(2)



        _________________________________________________________________
        settimeofday                                          System Call
        Set date and time.
        _________________________________________________________________


        SYNTAX

        #include <sys/time.h>

        int   settimeofday  (time_value, time_zone)
        struct timeval *  time_value;
        struct timezone * time_zone;


        PARAMETERS

        time_value     Address of an initialized structure giving the new
                       current time.


        time_zone      NULL or address of an initialized structure giving
                       the new time zone.


        DESCRIPTION

        Settimeofday sets the system's notion of the current Greenwich
        time and the current time zone to the values contained in the
        structures at the locations specified by <time_value> and
        <time_zone>.

        When the time is successfully changed, a log of the change is
        sent to the error logger device.

        If <time_zone> is NULL, the current time zone is not changed.

        The interpretation of the time value and time zone structures are
        discussed in gettimeofday.

        Although not enforced, it is unusual if the time zone correction,
        <time_zone.tz_minuteswest>, is not divisible by 60 minutes.

        Setting the system clock may interfere with other timing
        functions.


        ACCESS CONTROL

        Only the superuser may set the time of day.




        DG/UX 4.00                                                 Page 1
               Licensed material--property of copyright holder(s)





                                                          settimeofday(2)



        RETURN VALUE

        0              Completed successfully.


        -1             An error occurred.  Errno is set to indicate the
                       error.


        EXCEPTIONS

        Errno may be set to one of the following error codes:


        EFAULT         An argument address referenced invalid memory.


        EPERM          Permission to set the time is denied to the
                       calling process.


        SEE ALSO

        The related manual sections:  date(1),
        gettimeofday(2),
        ctime(3).




























        DG/UX 4.00                                                 Page 2
               Licensed material--property of copyright holder(s)



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