From 2632a33c527d8062c6343574ce03b97ad6348167 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sun, 10 Jan 2010 21:41:39 +0100 Subject: Change description of u*_stpncpy return value. --- doc/unistr.texi | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'doc') 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. -- cgit v1.2.1