From 1a724e3f3c1cb9472109291adee6cde2fcb8ff6c Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Sun, 4 Feb 2001 22:33:50 +0000 Subject: Add RETURN VALUES section Max alarm time is 100000000 seconds, not 2147483647 (as enforced by itimerfix() in kern_time.c) --- lib/libc/gen/alarm.3 | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'lib/libc') diff --git a/lib/libc/gen/alarm.3 b/lib/libc/gen/alarm.3 index 959036b5483..052e213c91a 100644 --- a/lib/libc/gen/alarm.3 +++ b/lib/libc/gen/alarm.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: alarm.3,v 1.8 2000/12/24 00:30:46 aaron Exp $ +.\" $OpenBSD: alarm.3,v 1.9 2001/02/04 22:33:49 millert Exp $ .\" .\" Copyright (c) 1980, 1991, 1993, 1994 .\" The Regents of the University of California. All rights reserved. @@ -59,7 +59,7 @@ returns the amount of time left on the clock. The maximum number of .Ar seconds allowed -is 2147483647. +is 100000000. .Pp If an alarm has been set with .Fn alarm , @@ -70,6 +70,11 @@ The request .Fn alarm "0" voids the current alarm. +.Sh RETURN VALUES +If the call succeeds, any time left remaining from a previous call is returned. +If an error occurs, the value \-1 is returned, and a more precise +error code is placed in the global variable +.Va errno . .Sh SEE ALSO .Xr setitimer 2 , .Xr sigaction 2 , -- cgit v1.2.3