Home

Traffic Server Software Developers Kit

INKfwrite

Writes a specified number of bytes to a file.

Prototype

int INKfwrite (INKFile filep, void *buf, int length)

Arguments

filep is the file to write to.

buf is the buffer that contains the data to be written.

length is the amount of data to write to filep.

Description

Attempts to write length bytes of data to the file pointed to by filep from the buffer buf. If the file was not opened for writing, then INKfwrite returns -1. Otherwise, INKfwrite returns the number of bytes written. Unless an error occurs when writing data to the file, the number of bytes written is equal to length. One common error is an insufficient amount of space on disk.