func Preallocate(size int64) Option {
	return optionFunc(func(c *config) error {
		if c.prealloc != defaultConfig().prealloc {
			return &werror{"multiple preallocations", nil}
		}
		if size < 0 {
			return &werror{"invalid preallocation size", nil}
		}
		c.prealloc = size
		return nil
	})
}
// Preallocate allocates the specified amount of bytes in the target
// file, regardless of the amount of content written.
// Not all filesystems and kernel versions support preallocating space.
Preallocate allocates the specified amount of bytes in the target
file, regardless of the amount of content written.
Not all filesystems and kernel versions support preallocating space.
// Preallocate allocates the specified amount of bytes in the target // file regardless of the amount of content written . // Not all filesystems and kernel versions support preallocating space .
func Preallocate(size int64) Option {
	return optionFunc(func(c *config) error {
		if c.prealloc != defaultConfig().prealloc {
			return &werror{"multiple preallocations", nil}
		}
		if size < 0 {
			return &werror{"invalid preallocation size", nil}
		}
		c.prealloc = size
		return nil
	})
}
func Preallocate ( size int64 ) Option { return optionFunc ( func ( c * config ) error { if c . prealloc != defaultConfig ( ) . prealloc { return & werror { " " , nil } } if size < 0 { return & werror { " " , nil } } c . prealloc = size return nil } ) }
Preallocate allocates the specified amount of bytes in the target
file, regardless of the amount of content written.
Preallocate allocates the specified amount of bytes in the target file regardless of the amount of content written .