putc, putcb, putcbp, putcf --
write to clists
int putc(int c, struct clist cp);
int putcb(struct cblock cbp, struct clist cp);
int putcbp(struct clist cp, char buf, int n);
void putcf(struct cblock cbp);
function adds one character to the
function adds the cblock
to the clist buffer.
function appends the specified number of characters from the
character buffer to the clist.
If the current cblock does not have room for these characters,
putcbp gets new cblocks
from the free list as needed.
function frees the specified cblock.
Character to be added to the clist buffer.
Pointer to the clist buffer.
Pointer to the cblock.
Character buffer from which to read characters.
Number of characters to read.
putc returns 0 if it places the specified character in the
buffer, or it returns -1 if there is no free space.
putcb always returns 0.
the number of characters put in the clist.
If no clists are available,
getcbp issues a CONFIG: error message using
and returns the number of characters actually stored.
putcf has no return value.
These functions can be used only with character device drivers.
They protect their internal critical sections of code using
Context and synchronization
Non-blockable, interrupt, user, or blockable
1, 2, 2mp, 3, 3mp, 4, 4mp, 5, 5mp, 6, 6mp
SVR5 DDI compatibility
This function is not supported for DDI drivers,
where serial drivers are implemented as STREAMS devices
and do not use clists and cblocks.
19 June 2005
© 2005 The SCO Group, Inc. All rights reserved.
OpenServer 5 HDK - June 2005