]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
(Parsing of Integers): Correct description of strtoul.
authorUlrich Drepper <drepper@redhat.com>
Fri, 30 Jan 1998 17:03:38 +0000 (17:03 +0000)
committerUlrich Drepper <drepper@redhat.com>
Fri, 30 Jan 1998 17:03:38 +0000 (17:03 +0000)
manual/arith.texi

index 59ddbd626fdf62ed9400d6e6279a543b1dc0b747..a0f14898d3cb2de6aab21b93909fa4d5c6967ccd 100644 (file)
@@ -506,16 +506,13 @@ There is an example at the end of this section.
 @deftypefun {unsigned long int} strtoul (const char *@var{string}, char **@var{tailptr}, int @var{base})
 The @code{strtoul} (``string-to-unsigned-long'') function is like
 @code{strtol} except it deals with unsigned numbers, and returns its
-value with type @code{unsigned long int}.  No @samp{+} or @samp{-} sign
-may appear before the number, but the syntax is otherwise the same as
+value with type @code{unsigned long int}.  If the number has a leading
+@samp{-} sign the negated value is returned.  The syntax is the same as
 described above for @code{strtol}.  The value returned in case of
 overflow is @code{ULONG_MAX} (@pxref{Range of Type}).
 
 Like @code{strtol} this function sets @code{errno} and returns the value
 @code{0ul} in case the value for @var{base} is not in the legal range.
-For @code{strtoul} this can happen in another situation.  In case the
-number to be converted is negative @code{strtoul} also sets @code{errno}
-to @code{EINVAL} and returns @code{0ul}.
 @end deftypefun
 
 @comment stdlib.h