]> git.ipfire.org Git - thirdparty/man-pages.git/blobdiff - man3/mbtowc.3
user_namespaces.7: Minor rewordings of recently added text
[thirdparty/man-pages.git] / man3 / mbtowc.3
index 37be2e81c4951105d6047195ec1f74bd0768cc48..9e470c1b9621aa75c04a04f5f16877eaa54d3884 100644 (file)
 .\"   OpenGroup's Single UNIX specification http://www.UNIX-systems.org/online.html
 .\"   ISO/IEC 9899:1999
 .\"
-.TH MBTOWC 3  2011-09-28 "GNU" "Linux Programmer's Manual"
+.TH MBTOWC 3  2019-03-06 "GNU" "Linux Programmer's Manual"
 .SH NAME
 mbtowc \- convert a multibyte sequence to a wide character
 .SH SYNOPSIS
 .nf
 .B #include <stdlib.h>
-.sp
+.PP
 .BI "int mbtowc(wchar_t *" pwc ", const char *" s ", size_t " n );
 .fi
 .SH DESCRIPTION
@@ -43,7 +43,7 @@ It updates an internal shift state known only to the
 function.
 If
 .I s
-does not point to a null byte (\(aq\\0\(aq), it returns the number
+does not point to a null byte (\(aq\e0\(aq), it returns the number
 of bytes that were consumed from
 .IR s ,
 otherwise it returns 0.
@@ -67,8 +67,7 @@ A different case is when
 is not NULL but
 .I pwc
 is NULL.
-In this
-case the
+In this case, the
 .BR mbtowc ()
 function behaves as above, except that it does not
 store the converted wide character in memory.
@@ -111,8 +110,20 @@ is NULL, the
 function
 returns nonzero if the encoding
 has nontrivial shift state, or zero if the encoding is stateless.
+.SH ATTRIBUTES
+For an explanation of the terms used in this section, see
+.BR attributes (7).
+.TS
+allbox;
+lb lb lb
+l l l.
+Interface      Attribute       Value
+T{
+.BR mbtowc ()
+T}     Thread safety   MT-Unsafe race
+.TE
 .SH CONFORMING TO
-C99.
+POSIX.1-2001, POSIX.1-2008, C99.
 .SH NOTES
 The behavior of
 .BR mbtowc ()
@@ -128,5 +139,8 @@ provides
 a better interface to the same functionality.
 .SH SEE ALSO
 .BR MB_CUR_MAX (3),
+.BR mblen (3),
 .BR mbrtowc (3),
-.BR mbstowcs (3)
+.BR mbstowcs (3),
+.BR wcstombs (3),
+.BR wctomb (3)