Lines Matching defs:buffer_allocated

243 static int enlarge_buffer(void **buffer, size_t *buffer_size, size_t *buffer_allocated) {
247 if (*buffer_allocated > *buffer_size)
256 *buffer_allocated = l;
261 int import_compress(ImportCompress *c, const void *data, size_t size, void **buffer, size_t *buffer_size, size_t *buffer_allocated) {
267 assert(buffer_allocated);
289 r = enlarge_buffer(buffer, buffer_size, buffer_allocated);
294 c->xz.avail_out = *buffer_allocated - *buffer_size;
300 *buffer_size += (*buffer_allocated - *buffer_size) - c->xz.avail_out;
311 r = enlarge_buffer(buffer, buffer_size, buffer_allocated);
316 c->gzip.avail_out = *buffer_allocated - *buffer_size;
322 *buffer_size += (*buffer_allocated - *buffer_size) - c->gzip.avail_out;
333 r = enlarge_buffer(buffer, buffer_size, buffer_allocated);
338 c->bzip2.avail_out = *buffer_allocated - *buffer_size;
344 *buffer_size += (*buffer_allocated - *buffer_size) - c->bzip2.avail_out;
351 if (*buffer_allocated < size) {
359 *buffer_allocated = size;
373 int import_compress_finish(ImportCompress *c, void **buffer, size_t *buffer_size, size_t *buffer_allocated) {
379 assert(buffer_allocated);
394 r = enlarge_buffer(buffer, buffer_size, buffer_allocated);
399 c->xz.avail_out = *buffer_allocated - *buffer_size;
405 *buffer_size += (*buffer_allocated - *buffer_size) - c->xz.avail_out;
415 r = enlarge_buffer(buffer, buffer_size, buffer_allocated);
420 c->gzip.avail_out = *buffer_allocated - *buffer_size;
426 *buffer_size += (*buffer_allocated - *buffer_size) - c->gzip.avail_out;
435 r = enlarge_buffer(buffer, buffer_size, buffer_allocated);
440 c->bzip2.avail_out = *buffer_allocated - *buffer_size;
446 *buffer_size += (*buffer_allocated - *buffer_size) - c->bzip2.avail_out;