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

NAME

6       wcsnlen - determine the length of a fixed-size wide-character string
7

SYNOPSIS

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

DESCRIPTION

22       The   wcsnlen()  function  is  the  wide-character  equivalent  of  the
23       strnlen(3) function.  It returns the number of wide-characters  in  the
24       string pointed to by s, not including the terminating null wide characā€
25       ter (L'\0'), but at most maxlen wide characters (note:  this  parameter
26       is not a byte count).  In doing this, wcsnlen() looks at only the first
27       maxlen wide characters at s and never beyond s+maxlen.
28

RETURN VALUE

30       The wcsnlen() function returns wcslen(s), if that is less than  maxlen,
31       or  maxlen  if  there  is no null wide character among the first maxlen
32       wide characters pointed to by s.
33

VERSIONS

35       The wcsnlen() function is provided in glibc since version 2.1.
36

CONFORMING TO

38       POSIX.1-2008.
39

SEE ALSO

41       strnlen(3), wcslen(3)
42

COLOPHON

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