Annotation of 42BSD/ingres/source/iutil/delete.c, revision 1.1

1.1     ! root        1: # include      <ingres.h>
        !             2: # include      <access.h>
        !             3: # include      <sccs.h>
        !             4: 
        !             5: SCCSID(@(#)delete.c    7.1     2/5/81)
        !             6: 
        !             7: /*
        !             8: **     Delete - delete the tuple specified by tid
        !             9: **
        !            10: **     Delete removes the tuple specified by tid
        !            11: **     and reclaims the tuple space.
        !            12: **
        !            13: **     returns:
        !            14: **             <0  fatal error
        !            15: **             0   success
        !            16: **             2   tuple specified by tid aleady deleted
        !            17: */
        !            18: 
        !            19: delete(dx, tidx)
        !            20: DESC   *dx;
        !            21: TID    *tidx;
        !            22: {
        !            23:        register DESC   *d;
        !            24:        register TID    *tid;
        !            25:        register int    i;
        !            26: 
        !            27:        d = dx;
        !            28:        tid = tidx;
        !            29: 
        !            30: #      ifdef xATR1
        !            31:        if (tTf(24, 8))
        !            32:        {
        !            33:                printf("delete: %.14s,", d->reldum.relid);
        !            34:                dumptid(tid);
        !            35:        }
        !            36: #      endif
        !            37: 
        !            38:        if (i = get_page(d, tid))
        !            39:                return (i);
        !            40: 
        !            41:        if (i = invalid(tid))
        !            42:                return (i);
        !            43: 
        !            44:        i = tup_len(tid);
        !            45: 
        !            46:        del_tuple(tid, i);
        !            47:        d->reladds--;
        !            48: 
        !            49:        return (0);
        !            50: }

unix.superglobalmegacorp.com

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