Mirror of :pserver:cvs@cvs.fefe.de:/cvs libowfat https://www.fefe.de/libowfat/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

13 lines
211 B

  1. #include "byte.h"
  2. #include "buffer.h"
  3. int buffer_getc(buffer* b,char* x) {
  4. if (b->p==b->n) {
  5. register int blen;
  6. if ((blen=buffer_feed(b))<=0) return blen;
  7. }
  8. *x=b->x[b->p];
  9. ++b->p;
  10. return 1;
  11. }