diff options
author | keramida <keramida@FreeBSD.org> | 2009-02-08 08:26:58 +0000 |
---|---|---|
committer | keramida <keramida@FreeBSD.org> | 2009-02-08 08:26:58 +0000 |
commit | 128fcdf861ec5a57a865a9821336441d8d211111 (patch) | |
tree | 84733b7498591d051cbf2c57414cc15ade21b29f /lib/libc/stdlib/atol.3 | |
parent | fd5959df47a24b0bbdb7ab8bf6dbf5bb3ae35309 (diff) | |
download | FreeBSD-src-128fcdf861ec5a57a865a9821336441d8d211111.zip FreeBSD-src-128fcdf861ec5a57a865a9821336441d8d211111.tar.gz |
Fix language on atol(3) manpage. Add a COMPATIBILITY section
stating that in FreeBSD the atol() and atoll() functions affect
errno in the same way as strtol() and stroll().
PR: docs/126487
Submitted by: edwin
Reviewed by: trhodes, gabor
MFC after: 1 week
Diffstat (limited to 'lib/libc/stdlib/atol.3')
-rw-r--r-- | lib/libc/stdlib/atol.3 | 35 |
1 files changed, 32 insertions, 3 deletions
diff --git a/lib/libc/stdlib/atol.3 b/lib/libc/stdlib/atol.3 index b9cf9e9..bb97c6f 100644 --- a/lib/libc/stdlib/atol.3 +++ b/lib/libc/stdlib/atol.3 @@ -32,7 +32,7 @@ .\" @(#)atol.3 8.1 (Berkeley) 6/4/93 .\" $FreeBSD$ .\" -.Dd November 28, 2001 +.Dd February 1, 2009 .Dt ATOL 3 .Os .Sh NAME @@ -78,13 +78,42 @@ representation. It is equivalent to: .Pp .Dl "strtoll(nptr, (char **)NULL, 10);" +.Sh COMPATIBILITY +The +.Fx +implementations of the +.Fn atol +and +.Fn atoll +functions are thin wrappers around +.Fn strtol +and +.Fn stroll +respectively, so these functions will affect the value of +.Va errno +in the same way that the +.Fn strtol +and +.Fn stroll +functions are able to. +This behavior of +.Fn atol +and +.Fn atoll +is not required by +.St -isoC +or +.St -isoC-c99 , +but it is allowed by all of +.St -isoC , St -isoC-99 +and +.St -p1003.1-2001 . .Sh ERRORS The functions .Fn atol and .Fn atoll -need not -affect the value of +may affect the value of .Va errno on an error. .Sh SEE ALSO |