Force files to a particular length
Truncation of files is used to force them to a particular length. If a file longer than specified, the trailing bytes are discarded, if it is shorter than specified it is padded with zeros.
mchars
) (length unsigned-int64
) ⇒ (ret <gnome-vfs-result>
)Truncate the file at text-uri to length bytes.
- text-uri
- string representing the file to be truncated.
- length
- length of the new file at text-uri.
- ret
- an integer representing the result of the operation.
<gnome-vfsuri>
) (length unsigned-int64
) ⇒ (ret <gnome-vfs-result>
)Truncate the file at uri to be only length bytes. Data past length bytes will be discarded.
- uri
- uri of the file to be truncated.
- length
- length of the new file at uri.
- ret
- an integer representing the result of the operation.