Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ alarm(2) — DG/UX 4.00

Media Vault

Software Library

Restoration Projects

Artifacts Sought



                                                                 alarm(2)



        _________________________________________________________________
        alarm                                                 System Call
        Set a process alarm clock.
        _________________________________________________________________


        SYNTAX

        None.

        unsigned        alarm  (num_seconds)
        unsigned        num_seconds;


        PARAMETERS

        num_seconds    The number of real-time seconds to wait before
                       sending SIGALRM to the caller.


        DESCRIPTION

        Alarm sets the caller's per-process real-time alarm clock to send
        the signal SIGALRM to the calling process after the number of
        real-time seconds specified by <num_seconds> have elapsed.  Alarm
        requests are not stacked;  successive calls reset the calling
        process's alarm clock.  If <num_seconds> is 0, any previous alarm
        request is canceled.  Alarm uses the ITIMER_REAL interval timer
        as is used by the setitimer() system call.   The fork() system
        call resets the alarm clock in the child to 0.  A process created
        by exec() inherits the time left on the old process's alarm
        clock.


        RETURN VALUE

        Alarm returns the amount of time remaining on the process's alarm
        clock from a previous call.  If zero, no previous alarm was set.


        EXCEPTIONS

        None.


        SEE ALSO

        The related system calls:  setitimer, getitimer, pause, signal,
        sigpause, sigset





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



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