From: Pádraig Brady
Date: Thu, 8 Aug 2019 12:31:41 +0000 (+0100) Subject: doc: clarify that truncate creates sparse files X-Git-Tag: v8.32~60 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=becf0db0daa1b81b70bb03d11fcea1e6ee0d8158;p=thirdparty%2Fcoreutils.git doc: clarify that truncate creates sparse files * src/truncate.c (usage): Explicitly mention "sparse". * doc/coreutils.texi (truncate invocation): Likewise. Addresses https://bugs.gnu.org/36963 --- diff --git a/doc/coreutils.texi b/doc/coreutils.texi index 42c0e36b88..b552cc1057 100644 --- a/doc/coreutils.texi +++ b/doc/coreutils.texi @@ -12593,8 +12593,8 @@ Any @var{file} that does not exist is created. @cindex sparse files, creating @cindex holes, creating files with If a @var{file} is larger than the specified size, the extra data is lost. -If a @var{file} is shorter, it is extended and the extended part (or hole) -reads as zero bytes. +If a @var{file} is shorter, it is extended and the sparse extended part +(or hole) reads as zero bytes. The program accepts the following options. Also see @ref{Common options}. diff --git a/src/truncate.c b/src/truncate.c index aa355123e4..4494ab51a3 100644 --- a/src/truncate.c +++ b/src/truncate.c @@ -74,7 +74,7 @@ Shrink or extend the size of each FILE to the specified size\n\ A FILE argument that does not exist is created.\n\ \n\ If a FILE is larger than the specified size, the extra data is lost.\n\ -If a FILE is shorter, it is extended and the extended part (hole)\n\ +If a FILE is shorter, it is extended and the sparse extended part (hole)\n\ reads as zero bytes.\n\ "), stdout);