4mARCHIVE_WRITE_BLOCKSIZE24m(3)	 Library Functions Manual4mARCHIVE_WRITE_BLOCKSIZE24m(3)

1mNAME0m
       archive_write_get_bytes_per_block,   archive_write_set_bytes_per_block,
       archive_write_get_bytes_in_last_block,
       archive_write_set_bytes_in_last_block — functions for creating archives

1mLIBRARY0m
       Streaming Archive Library (libarchive, -larchive)

1mSYNOPSIS0m
       1m#include <archive.h>0m

       4mint0m
       1marchive_write_get_bytes_per_block22m(4mstruct24m 4marchive24m 4m*24m);

       4mint0m
       1marchive_write_set_bytes_per_block22m(4mstruct24m	    4marchive24m	   4m*24m,
	   4mint24m 4mbytes_per_block24m);

       4mint0m
       1marchive_write_get_bytes_in_last_block22m(4mstruct24m 4marchive24m 4m*24m);

       4mint0m
       1marchive_write_set_bytes_in_last_block22m(4mstruct24m 4marchive24m 4m*24m, 4mint24m);

1mDESCRIPTION0m
       1marchive_write_set_bytes_per_block22m()
	       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 di‐
	       rectly to the write callback as they occur.

       1marchive_write_get_bytes_per_block22m()
	       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.

       1marchive_write_set_bytes_in_last_block22m()
	       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 un‐
	       padded.	The default is to pad the last block to the full block
	       size (note that	1marchive_write_open_filename22m()  will  set  this
	       based  on  the  file  type).  Unlike the other “set” functions,
	       this function can be called after the archive is opened.

       1marchive_write_get_bytes_in_last_block22m()
	       Retrieve the currently-set value for last block size.  A	 value
	       of  -1  here indicates that the library should use default val‐
	       ues.

1mRETURN VALUES0m
       1marchive_write_set_bytes_per_block22m()					and
       1marchive_write_set_bytes_in_last_block22m()  return  1mARCHIVE_OK 22mon success,
       or 1mARCHIVE_FATAL22m.

       1marchive_write_get_bytes_per_block22m()					and
       1marchive_write_get_bytes_in_last_block22m()   return  currently	 configured
       block size (1m-1 22mindicates the default block size), or 1mARCHIVE_FATAL22m.

1mERRORS0m
       Detailed error codes and textual descriptions are  available  from  the
       1marchive_errno22m() and 1marchive_error_string22m() functions.

1mSEE ALSO0m
       4mtar24m(1), 4marchive_write_set_options24m(3), 4mlibarchive24m(3), 4mcpio24m(5), 4mmtree24m(5),
       4mtar24m(5)

Debian			       February 2, 2012	    4mARCHIVE_WRITE_BLOCKSIZE24m(3)
