Annotation of 43BSDReno/contrib/isode-beta/psap/ps_io.c, revision 1.1.1.1

1.1       root        1: /* ps_io.c - presentation stream I/O dispatch */
                      2: 
                      3: #ifndef        lint
                      4: static char *rcsid = "$Header: /f/osi/psap/RCS/ps_io.c,v 7.0 89/11/23 22:13:24 mrose Rel $";
                      5: #endif
                      6: 
                      7: /* 
                      8:  * $Header: /f/osi/psap/RCS/ps_io.c,v 7.0 89/11/23 22:13:24 mrose Rel $
                      9:  *
                     10:  *
                     11:  * $Log:       ps_io.c,v $
                     12:  * Revision 7.0  89/11/23  22:13:24  mrose
                     13:  * Release 6.0
                     14:  * 
                     15:  */
                     16: 
                     17: /*
                     18:  *                               NOTICE
                     19:  *
                     20:  *    Acquisition, use, and distribution of this module and related
                     21:  *    materials are subject to the restrictions of a license agreement.
                     22:  *    Consult the Preface in the User's Manual for the full terms of
                     23:  *    this agreement.
                     24:  *
                     25:  */
                     26: 
                     27: 
                     28: /* LINTLIBRARY */
                     29: 
                     30: #include <stdio.h>
                     31: #include "psap.h"
                     32: 
                     33: /*  */
                     34: 
                     35: int    ps_io (ps, io, data, n, in_line)
                     36: register PS    ps;
                     37: register IFP   io;
                     38: register PElementData data;
                     39: register PElementLen n;
                     40: int    in_line;
                     41: {
                     42:     register int    cc;
                     43: 
                     44:     if (io == NULLIFP)
                     45:        return ps_seterr (ps, PS_ERR_EOF, NOTOK);
                     46: 
                     47:     while (n > 0)
                     48:        switch (cc = (*io) (ps, data, n, in_line)) {
                     49:            case NOTOK: 
                     50:                return NOTOK;
                     51: 
                     52:            case OK: 
                     53:                return ps_seterr (ps, PS_ERR_EOF, NOTOK);
                     54: 
                     55:            default: 
                     56:                data += cc, n -= cc;
                     57:                ps -> ps_byteno += cc;
                     58:                break;
                     59:        }
                     60: 
                     61:     return OK;
                     62: }

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.