Lines Matching defs:cnt

71  *	buf          ptr        buf+cnt   buf+size
85 * buf ptr buf+cnt buf+size
93 * buf ptr buf+cnt buf+size
96 * When writing, ptr may go beyond buf+cnt.
121 * buf ptr buf+cnt buf+size
124 * Buf+cnt indicates the end of the used buffer and is always >= ptr.
125 * If the buffer is the last in the chain, Buf+cnt is the end of "file".
131 * StreamCnt every buffer in the list has its own cnt field, which is
145 * buf ptr buf+cnt buf+size
147 * Ptr is used for reading only, writing is done at buf+cnt.
150 * this buffer is StreamWBuf + BufHeader(StreamWBuf)->cnt.
161 * StreamCnt every buffer in the list has its own cnt field, which is copied
307 StreamCnt(nst) = StreamBufHeader(nst)->cnt; \
312 StreamCnt(nst) = StreamBufHeader(nst)->cnt; \
318 buf_header->cnt = 0; \
375 uword cnt;
1460 count += BufHeader(buf)->cnt - (ptr - buf);
1462 while(ptr < buf + BufHeader(buf)->cnt)
1479 BufHeader(StreamWBuf(nst))->cnt - (StreamPtr(nst)-StreamBuf(nst));
1482 (StreamSize(nst)-(StreamPtr(nst)-StreamBuf(nst))) + BufHeader(StreamWBuf(nst))->cnt;
1496 count += BufHeader(buf)->cnt;
1516 count += BufHeader(buf)->cnt;
1517 for (ptr = buf; ptr < buf + BufHeader(buf)->cnt; )
1573 wptr = wbuf + BufHeader(wbuf)->cnt;
1574 bfree = StreamSize(nst) - BufHeader(wbuf)->cnt;
1583 BufHeader(wbuf)->cnt = wptr - wbuf;
1585 StreamCnt(nst) = BufHeader(wbuf)->cnt;
1587 StreamOffset(nst) += BufHeader(wbuf)->cnt;
1605 for(i = BufHeader(wbuf)->cnt; i < BufHeader(wbuf)->cnt + count; ++i)
1607 BufHeader(wbuf)->cnt += count;
1609 StreamCnt(nst) = BufHeader(wbuf)->cnt;
1611 wbuf[BufHeader(wbuf)->cnt] = EOB_MARK;
1633 StreamCnt(nst) = StreamBufHeader(nst)->cnt = StreamPtr(nst) - StreamBuf(nst);
1652 StreamCnt(nst) = StreamBufHeader(nst)->cnt = StreamPtr(nst) - StreamBuf(nst);
2036 StreamCnt(nst) = BufHeader(StreamBuf(nst))->cnt = pos - StreamOffset(nst);
2049 StreamCnt(nst) = BufHeader(StreamBuf(nst))->cnt = StreamSize(nst);
2062 StreamCnt(nst) = BufHeader(StreamBuf(nst))->cnt = StreamSize(nst);
2069 StreamCnt(nst) = BufHeader(StreamBuf(nst))->cnt = pos - StreamOffset(nst);
2342 StreamCnt(nst) = StreamBufHeader(nst)->cnt = StreamPtr(nst) - StreamBuf(nst);
3021 int cnt = 0;
3025 cnt = write(fd, buf, n);
3026 if (cnt == n)
3028 else if (cnt < 0 )
3039 n -= cnt;
3040 buf += cnt;