Home | History | Annotate | Download | only in qemu

Lines Matching refs:buf_index

176     int buf_index;
447 if (f->is_write && f->buf_index > 0) {
450 len = f->put_buffer(f->opaque, f->buf, f->buf_offset, f->buf_index);
452 f->buf_offset += f->buf_index;
455 f->buf_index = 0;
471 f->buf_index = 0;
497 if (!f->has_error && f->is_write == 0 && f->buf_index > 0) {
504 l = IO_BUF_SIZE - f->buf_index;
507 memcpy(f->buf + f->buf_index, buf, l);
509 f->buf_index += l;
512 if (f->buf_index >= IO_BUF_SIZE)
519 if (!f->has_error && f->is_write == 0 && f->buf_index > 0) {
525 f->buf[f->buf_index++] = v;
527 if (f->buf_index >= IO_BUF_SIZE)
540 l = f->buf_size - f->buf_index;
543 l = f->buf_size - f->buf_index;
549 memcpy(buf, f->buf + f->buf_index, l);
550 f->buf_index += l;
562 if (f->buf_index >= f->buf_size) {
564 if (f->buf_index >= f->buf_size)
567 return f->buf[f->buf_index++];
603 return f->buf_offset - f->buf_size + f->buf_index;
621 f->buf_index = 0;