Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

mblen - get number of bytes in multi-byte character

&pagelevel(4)&pagelevel

Syntax

#include <stdlib.h>

int mblen(const char *s, size_t n);

Description mblen() returns the number of bytes of a multi-byte character to which s points. A maximum

of n bytes in s are evaluated.

No characters consisting of multiple bytes are implemented in this version. Multi-byte
characters always have a length of 1 (MB_CUR_MAX =1).

Return val.

-1

0

1

if n = 0.

if s is a null pointer or points to a null byte.

in all other cases.

See also

mbstowcs(), mbtowc(), wcstombs(), wctomb(), stdlib.h.