Netbuf_Grab; Netbuf_Open - Netscape ENTERPRISE SERVER 6.1 - NSAPI PROGRAMMER GUIDE Manual

Nsapi
Table of Contents

Advertisement

Returns
The integer representing the character, if one was retrieved or the constant
or
, for end of file or error
IO_ERROR
Parameters
is the buffer from which to retrieve one character.
netbuf b
See also
netbuf_buf2sd, netbuf_close

netbuf_grab

The
function reads
netbuf_grab
(
) socket into the network buffer. If the buffer is not large enough it is resized.
buf
The data can be retrieved from
This function is used by the function
Syntax
int netbuf_grab(netbuf *buf, int sz);
Returns
The number of bytes actually read (between 1 and
successful or the constant
Parameters
is the buffer to read into.
netbuf *buf
is the number of bytes to read.
int sz
See also
netbuf_buf2sd, netbuf_close, netbuf_getc, netbuf_open

netbuf_open

The
function opens a new network buffer and returns it. You can use
netbuf_open
to create a
netbuf_open
Syntax
netbuf* netbuf_open(SYS_NETFD sd, int sz);
Returns
A pointer to a new
netbuf
,
netbuf_grab
number of bytes from the network buffer's
sz
on success.
buf->inbuf
netbuf_buf2sd
or
IO_EOF
IO_ERROR
structure and start using buffered I/O on a socket.
netbuf
structure (network buffer)
NSAPI Functions (in Alphabetical Order)
,
netbuf_open
.
), if the operation was
sz
, for end of file or error
Chapter 5
NSAPI Function Reference
IO_EOF
157

Advertisement

Table of Contents
loading

This manual is also suitable for:

Enterprise server 6.1

Table of Contents