.\" Copyright (c) Bruno Haible .\" .\" %%%LICENSE_START(GPLv2+_DOC_ONEPARA) .\" This is free documentation; you can redistribute it and/or .\" modify it under the terms of the GNU General Public License as .\" published by the Free Software Foundation; either version 2 of .\" the License, or (at your option) any later version. .\" %%%LICENSE_END .\" .\" References consulted: .\" GNU glibc-2 source code and manual .\" Dinkumware C library reference http://www.dinkumware.com/ .\" OpenGroup's Single UNIX specification http://www.UNIX-systems.org/online.html .\" .\"******************************************************************* .\" .\" This file was generated with po4a. Translate the source file. .\" .\"******************************************************************* .\" .\" Translated Mon Oct 18 22:36:21 JST 1999 .\" by FUJIWARA Teruyoshi .\" Updated & Modified Sun Jun 6 13:23:46 JST 2004 .\" by Yuichi SATO .\" Updated 2013-07-22, Akihiro MOTOKI .\" .TH WCSDUP 3 2017\-09\-15 GNU "Linux Programmer's Manual" .SH 名前 wcsdup \- ワイド文字文字列を複製する .SH 書式 .nf \fB#include \fP .PP \fBwchar_t *wcsdup(const wchar_t *\fP\fIs\fP\fB);\fP .fi .PP .RS -4 glibc 向けの機能検査マクロの要件 (\fBfeature_test_macros\fP(7) 参照): .RE .PP \fBwcsdup\fP(): .PD 0 .ad l .RS 4 .TP 4 glibc 2.10 以降: _POSIX_C_SOURCE\ >=\ 200809L .TP glibc 2.10 より前: _GNU_SOURCE .RE .ad .PD .SH 説明 \fBwcsdup\fP() 関数は、 \fBstrdup\fP(3) 関数のワイド文字版である。 この関数はポインター \fIs\fP が指し示すワイド文字文字列の複製を 新しい領域に割り当てて返す。 .PP 新しいワイド文字文字列のためのメモリーは \fBmalloc\fP(3) を使って割り当てられる。 この領域は \fBfree\fP(3) を使って解放すべきである。 .SH 返り値 成功すると、 \fBwcsdup\fP() 関数は、新しいワイド文字文字列へのポインターを返す。 エラーの場合、 NULL が返り、 \fIerrno\fP にエラーの原因を示す値が設定される。 .SH エラー .TP \fBENOMEM\fP 複製文字列を割り当てるのに十分なメモリーがない。 .SH 属性 この節で使用されている用語の説明については、 \fBattributes\fP(7) を参照。 .TS allbox; lb lb lb l l l. インターフェース 属性 値 T{ \fBwcsdup\fP() T} Thread safety MT\-Safe .TE .sp 1 .SH 準拠 .\" present in libc5 and glibc 2.0 and later POSIX.1\-2008. この関数は POSIX.1\-2001 では規定されていないが、 Linux 以外の他のシステムで広く利用可能である。 .SH 関連項目 \fBstrdup\fP(3), \fBwcscpy\fP(3) .SH この文書について この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 5.10 の一部である。プロジェクトの説明とバグ報告に関する情報は \%https://www.kernel.org/doc/man\-pages/ に書かれている。