X-Git-Url: http://git.osdn.net/view?a=blobdiff_plain;f=release%2Fman2%2Ftruncate.2;h=c473740231acf9928522249047fd99ea9ad624bd;hb=385329a00e7910812cffee7720cbd7ae0321afc5;hp=a6313c1106e4d7fb47a360464eaa2be0bbfb107b;hpb=a2b0f650fa5e3f097a33752f9ee5626f8d678fd8;p=linuxjm%2FLDP_man-pages.git diff --git a/release/man2/truncate.2 b/release/man2/truncate.2 index a6313c11..c4737402 100644 --- a/release/man2/truncate.2 +++ b/release/man2/truncate.2 @@ -96,7 +96,7 @@ _BSD_SOURCE || _XOPEN_SOURCE\ >=\ 500 || _XOPEN_SOURCE\ &&\ _XOPEN_SOURCE_EXTEND \fIlength\fP バイトの長さになるように延長する、もしくは切り詰める。 .LP もし切り詰める前のファイルが \fIlength\fP より長ければ、length バイトを越える部分のデータは失われる。 もし切り詰める前のファイルが -\fIlength\fP より短かければ、伸張される。 伸張された部分を読んだ場合は NULL バイト (\(aq\e0\(aq) の列が返される。 +\fIlength\fP より短かければ、伸張される。 伸張された部分を読んだ場合はヌルバイト (\(aq\e0\(aq) の列が返される。 .LP ファイルオフセットは変更されない。 .LP @@ -148,11 +148,10 @@ inode の更新時に I/O エラーが発生した。 \fBEPERM\fP .\" This happens for at least MSDOS and VFAT filesystems .\" on kernel 2.6.13 -The underlying filesystem does not support extending a file beyond its -current size. +下層にあるファイルシステムでは、現在のファイル長を越えて ファイルを伸長することができない。 .TP \fBEROFS\fP -The named file resides on a read\-only filesystem. +ファイルが読み込み専用 (read only) のファイルシステム上にある。 .TP \fBETXTBSY\fP 指定されたファイルは実行されているファイルである。 @@ -183,15 +182,15 @@ The named file resides on a read\-only filesystem. 4.4BSD, SVr4, POSIX.1\-2001 (これらのコールは 4.2BSD で初めて登場した)。 .SH 注意 .\" At the very least: OSF/1, Solaris 7, and FreeBSD conform, mtk, Jan 2002 -The details in DESCRIPTION are for XSI\-compliant systems. For -non\-XSI\-compliant systems, the POSIX standard allows two behaviors for -\fBftruncate\fP() when \fIlength\fP exceeds the file length (note that -\fBtruncate\fP() is not specified at all in such an environment): either -returning an error, or extending the file. Like most UNIX implementations, -Linux follows the XSI requirement when dealing with native filesystems. -However, some nonnative filesystems do not permit \fBtruncate\fP() and -\fBftruncate\fP() to be used to extend a file beyond its current length: a -notable example on Linux is VFAT. +「説明」の節で述べた詳細は XSI 準拠のシステムについてのものである。 +XSI 非準拠のシステムの場合、POSIX 標準は \fBftruncate\fP() に対して \fIlength\fP が +ファイルの長さより長かった場合、 エラーを返すかファイルを伸張するかの二つの +動作を許容している。 \fBtruncate\fP() に対しては全く規定されていない。 +ほとんどの UNIX 実装と同様、Linux はネイティブ (Linux 由来) の ファイルシステム +の扱いでは XSI 要求仕様にしたがっている。 しかしながら、いくつかの非ネイティブ +のファイルシステムでは、 \fBtruncate\fP() や \fBftruncate\fP() を使って現在のファイル +長を越えてファイルを伸長することができない。 Linux での有名な例としては +VFAT がある。 元々の Linux の \fBtruncate\fP() と \fBftruncate\fP() システムコールは 大きなファイルオフセットを扱えるように設計されていなかった。 @@ -210,6 +209,6 @@ glibc 2.12 のヘッダファイルにはバグがあり、 \fBftruncate\fP() .SH 関連項目 \fBopen\fP(2), \fBstat\fP(2), \fBpath_resolution\fP(7) .SH この文書について -この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.54 の一部 +この man ページは Linux \fIman\-pages\fP プロジェクトのリリース 3.68 の一部 である。プロジェクトの説明とバグ報告に関する情報は http://www.kernel.org/doc/man\-pages/ に書かれている。