Filebuf_Open; Filebuf_Open_Nostat - Netscape ENTERPRISE SERVER 6.0 - NSAPI PROGRAMMER GUIDE Manual

Nsapi
Table of Contents

Advertisement

filebuf_open

The
function opens a new file buffer for a previously opened file. It
filebuf_open
returns a new buffer structure. Buffered files provide more efficient file access by
guaranteeing the use of buffered file I/O in environments where it is not supported
by the operating system.
Syntax
filebuf *filebuf_open(SYS_FILE fd, int sz);
Returns
A pointer to a new buffer structure to hold the data, if successful or
buffer could be opened.
Parameters
is the platform-independent file descriptor of the file which has
SYS_FILE fd
already been opened.
is the size, in bytes, to be used for the buffer.
int sz
Example
filebuf *buf = filebuf_open(fd, FILE_BUFFERSIZE);
if (!buf) {
system_fclose(fd);
}
See also
filebuf_getc, filebuf_buf2sd, filebuf_close, filebuf_open_nostat

filebuf_open_nostat

The
filebuf_open_nostat
opened file. It returns a new buffer structure. Buffered files provide more efficient
file access by guaranteeing the use of buffered file I/O in environments where it is
not supported by the operating system.
This function is the same
need to call the
request_stat_path
be passed in.
Syntax
filebuf* filebuf_open_nostat(SYS_FILE fd, int sz,
struct stat *finfo);
function opens a new file buffer for a previously
, but is more efficient, since it does not
filebuf_open
function. It requires that the stat information
NSAPI Functions (in Alphabetical Order)
NULL
Chapter 5
NSAPI Function Reference
if no
145

Advertisement

Table of Contents
loading

This manual is also suitable for:

Enterprise server 6.0

Table of Contents