1WCPNCPY(3)                 Linux Programmer's Manual                WCPNCPY(3)
2
3
4

NAME

6       wcpncpy  -  copy  a  fixed-size  string of wide characters, returning a
7       pointer to its end
8

SYNOPSIS

10       #include <wchar.h>
11
12       wchar_t *wcpncpy(wchar_t *dest, const wchar_t *src, size_t n);
13
14   Feature Test Macro Requirements for glibc (see feature_test_macros(7)):
15
16       wcpncpy():
17           Since glibc 2.10:
18               _XOPEN_SOURCE >= 700 || _POSIX_C_SOURCE >= 200809L
19           Before glibc 2.10:
20               _GNU_SOURCE
21

DESCRIPTION

23       The wcpncpy() function is the wide-character  equivalent  of  the  stp‐
24       ncpy(3)  function.   It copies at most n wide characters from the wide-
25       character string pointed to by src, including the terminating null wide
26       (L'\0'),  to  the  array pointed to by dest.  Exactly n wide characters
27       are written at dest.  If the length wcslen(src) is smaller than n,  the
28       remaining  wide  characters  in the array pointed to by dest are filled
29       with L'\0' characters.  If the length wcslen(src) is greater  or  equal
30       to n, the string pointed to by dest will not be L'\0' terminated.
31
32       The strings may not overlap.
33
34       The programmer must ensure that there is room for at least n wide char‐
35       acters at dest.
36

RETURN VALUE

38       wcpncpy() returns a pointer to the last wide  character  written,  that
39       is, dest+n-1".
40

CONFORMING TO

42       POSIX.1-2008.
43

SEE ALSO

45       stpncpy(3), wcsncpy(3)
46

COLOPHON

48       This  page  is  part of release 3.53 of the Linux man-pages project.  A
49       description of the project, and information about reporting  bugs,  can
50       be found at http://www.kernel.org/doc/man-pages/.
51
52
53
54GNU                               2011-10-01                        WCPNCPY(3)
Impressum