futility/updater_archive.c
/*
 * Reads a file from archive.
 * If entry name (fname) is an absolute path (/file), always read
 * from real file system.
 * Returns 0 on success (data and size reflects the file content),
 * otherwise non-zero as failure.
 */
Reads a file from archive.
If entry name (fname) is an absolute path (/file), always read
from real file system.
Returns 0 on success (data and size reflects the file content),
otherwise non-zero as failure.
Reads a file from archive . If entry name ( fname ) is an absolute path ( / file ) always read from real file system . Returns 0 on success ( data and size reflects the file content ) otherwise non - zero as failure .
int archive_read_file(struct archive *ar, const char *fname,
		      uint8_t **data, uint32_t *size, int64_t *mtime)
{
	if (!ar || *fname == '/')
		return archive_fallback_read_file(NULL, fname, data, size, mtime);
	return ar->read_file(ar->handle, fname, data, size, mtime);
}
int archive_read_file ( struct archive * ar , const char * fname , uint8_t * * data , uint32_t * size , int64_t * mtime ) { if ( ! ar || * fname == ' ' ) return archive_fallback_read_file ( NULL , fname , data , size , mtime ) ; return ar -> read_file ( ar -> handle , fname , data , size , mtime ) ; }
Reads a file from archive.
Reads a file from archive .