mirror of https://github.com/mkerrisk/man-pages
iconv.3: Upstream useful NOTE from Debian
Warn the reader that the pointer arguments can't be interpreted as C style strings. Also, note possible alignment requirements for the referenced bytes sequences, Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
parent
f9b75bd469
commit
2d17a61d47
19
man3/iconv.3
19
man3/iconv.3
|
@ -139,6 +139,25 @@ An incomplete multibyte sequence has been encountered in the input.
|
|||
This function is available in glibc since version 2.1.
|
||||
.SH "CONFORMING TO"
|
||||
POSIX.1-2001.
|
||||
.SH NOTES
|
||||
Although
|
||||
.I inbuf
|
||||
and
|
||||
.I outbuf
|
||||
are typed as
|
||||
.IR "char\ **" ,
|
||||
this does not mean that the objects they point can be interpreted
|
||||
as C strings or as arrays of characters:
|
||||
the interpretation of character byte sequences is
|
||||
handled internally by the conversion functions.
|
||||
In some encodings, a zero byte may be a valid part of a multibyte character.
|
||||
|
||||
The caller of
|
||||
.BR iconv ()
|
||||
must ensure that the pointers passed to the function are suitable
|
||||
for accessing characters in the appropriate character set.
|
||||
This includes ensuring correct alignment on platforms that have
|
||||
tight restrictions on alignment.
|
||||
.SH "SEE ALSO"
|
||||
.BR iconv_close (3),
|
||||
.BR iconv_open (3)
|
||||
|
|
Loading…
Reference in New Issue