Mercurial > hg > cdb
comparison buffer_0.c @ 0:2cb46628feec
from cdb-0.75 per http://cr.yp.to/cdb.html,
retrieved 2025-01-03,
contents appear to have been create on 2000-02-19
| author | Henry S. Thompson <ht@inf.ed.ac.uk> |
|---|---|
| date | Wed, 29 Jan 2025 10:50:34 +0000 |
| parents | |
| children | 3bfef1f22a97 |
comparison
equal
deleted
inserted
replaced
| -1:000000000000 | 0:2cb46628feec |
|---|---|
| 1 #include "readwrite.h" | |
| 2 #include "buffer.h" | |
| 3 | |
| 4 int buffer_0_read(fd,buf,len) int fd; char *buf; int len; | |
| 5 { | |
| 6 if (buffer_flush(buffer_1) == -1) return -1; | |
| 7 return read(fd,buf,len); | |
| 8 } | |
| 9 | |
| 10 char buffer_0_space[BUFFER_INSIZE]; | |
| 11 static buffer it = BUFFER_INIT(buffer_0_read,0,buffer_0_space,sizeof buffer_0_space); | |
| 12 buffer *buffer_0 = ⁢ |
