summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorBruno Haible <bruno@clisp.org>2010-01-10 21:41:39 +0100
committerBruno Haible <bruno@clisp.org>2010-01-10 21:41:39 +0100
commit2632a33c527d8062c6343574ce03b97ad6348167 (patch)
tree1c7d044d7cc48bbaec54c536e101b8e25d9f17e5 /doc
parentd75204a8c92e4a404d7c88de68ddacc7083ecb7e (diff)
downloadlibunistring-2632a33c527d8062c6343574ce03b97ad6348167.tar.gz
Change description of u*_stpncpy return value.
Diffstat (limited to 'doc')
-rw-r--r--doc/unistr.texi7
1 files changed, 5 insertions, 2 deletions
diff --git a/doc/unistr.texi b/doc/unistr.texi
index 9c6261b..ad04f42 100644
--- a/doc/unistr.texi
+++ b/doc/unistr.texi
@@ -324,8 +324,11 @@ that it operates on Unicode strings.
@deftypefun {uint8_t *} u8_stpncpy (uint8_t *@var{dest}, const uint8_t *@var{src}, size_t @var{n})
@deftypefunx {uint16_t *} u16_stpncpy (uint16_t *@var{dest}, const uint16_t *@var{src}, size_t @var{n})
@deftypefunx {uint32_t *} u32_stpncpy (uint32_t *@var{dest}, const uint32_t *@var{src}, size_t @var{n})
-Copies no more than @var{n} units of @var{src} to @var{dest}, returning the
-address of the last unit written into @var{dest}.
+Copies no more than @var{n} units of @var{src} to @var{dest}. Returns a
+pointer past the last non-NUL unit written into @var{dest}. In other words,
+if the units written into @var{dest} include a NUL, the return value is the
+address of the first such NUL unit, otherwise it is
+@code{@var{dest} + @var{n}}.
This function is similar to @posixfunc{stpncpy}, except that it operates on
Unicode strings.