Manpages - archive_write_blocksize.3

Streaming Archive Library (libarchive, -larchive)

Sets the block size used for writing the archive data. Every call to the write callback function, except possibly the last one, will use this value for the length. The default is to use a block size of 10240 bytes. Note that a block size of zero will suppress internal blocking and cause writes to be sent directly to the write callback as they occur.

Retrieve the block size to be used for writing. A value of -1 here indicates that the library should use default values. A value of zero indicates that internal blocking is suppressed.

Sets the block size used for writing the last block. If this value is zero, the last block will be padded to the same size as the other blocks. Otherwise, the final block will be padded to a multiple of this size. In particular, setting it to 1 will cause the final block to not be padded. For compressed output, any padding generated by this option is applied only after the compression. The uncompressed data is always unpadded. The default is to pad the last block to the full block size (note that

will set this based on the file type). Unlike the other

functions, this function can be called after the archive is opened.

Retrieve the currently-set value for last block size. A value of -1 here indicates that the library should use default values.

and

return

on success, or

and

return currently configured block size

indicates the default block size

or

Detailed error codes and textual descriptions are available from the

and

functions.

Author: dt

Created: 2022-02-20 Sun 14:31