06.08.2013 Views

pSOSystem System Calls - Read

pSOSystem System Calls - Read

pSOSystem System Calls - Read

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

pHILE+ <strong>System</strong> <strong>Calls</strong> read_vol<br />

read_vol <strong>Read</strong>s directly from a pHILE+ formatted volume.<br />

#include <br />

unsigned long read_vol(<br />

char *device, /* volume name */<br />

unsigned long block, /* base block */<br />

unsigned long index, /* byte offset */<br />

unsigned long bcount, /* number of bytes to read */<br />

void *buffer /* input buffer */<br />

)<br />

Volume Types<br />

Description<br />

Arguments<br />

Return Value<br />

pHILE+, MS-DOS, and CD-ROM formatted volumes.<br />

read_vol() reads data directly from a volume, bypassing the file system<br />

organization imposed by the pHILE+ file system manager.<br />

device Points to the null-terminated name of the volume to read.<br />

block Identifies the logical block number to begin reading.<br />

index Specifies where to begin reading within the specified block.<br />

bcount Specifies the number of bytes to read.<br />

buffer Points to the memory area to receive the data.<br />

This system call returns 0 on success or an error code on failure.<br />

<strong>pSO<strong>System</strong></strong> <strong>System</strong> <strong>Calls</strong> 2-99<br />

2

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!