diff options
author | 2003-04-21 21:49:40 +0000 | |
---|---|---|
committer | 2003-04-21 21:49:40 +0000 | |
commit | 87c1655094ed7ade93d57a7ceac3e8580e412721 (patch) | |
tree | 052e86664a9f281cda77e8f60bdc9b10713f6f70 /lib/libc | |
parent | Fix the load_size which is used by ldd to print end address. (diff) | |
download | wireguard-openbsd-87c1655094ed7ade93d57a7ceac3e8580e412721.tar.xz wireguard-openbsd-87c1655094ed7ade93d57a7ceac3e8580e412721.zip |
Mention that stroul() et al *do* accept negative numbers, they
just (effectively) cast to unsigned. ho@ OK
Diffstat (limited to 'lib/libc')
-rw-r--r-- | lib/libc/stdlib/strtoul.3 | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/libc/stdlib/strtoul.3 b/lib/libc/stdlib/strtoul.3 index fd6a235309f..0e804ec3f9e 100644 --- a/lib/libc/stdlib/strtoul.3 +++ b/lib/libc/stdlib/strtoul.3 @@ -33,7 +33,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $OpenBSD: strtoul.3,v 1.12 2003/03/06 18:19:26 kjell Exp $ +.\" $OpenBSD: strtoul.3,v 1.13 2003/04/21 21:49:40 millert Exp $ .\" .Dd June 25, 1992 .Dt STRTOUL 3 @@ -83,6 +83,11 @@ The conversion is done according to the given .Fa base , which must be a number between 2 and 36 inclusive or the special value 0. +If the string in +.Fa nptr +represents a negative number, it will be converted to its unsigned equivalent. +This behavior is consistent with what happens when a signed integer type is +cast to its unsigned counterpart. .Pp The string may begin with an arbitrary amount of whitespace (as determined by |