func: int ffio_rewind_with_probe_data(AVIOContext *s,unsigned char **bufp,int buf_size) int64_t buffer_start ; int buffer_size ; int overlap ; int new_size ; int alloc_size ; uint8_t * buf = * bufp ; if ( s -> write_flag )  buffer_size = ( s -> buf_end - s -> buffer ); if ( ( buffer_start = s -> pos - buffer_size ) > buf_size )  overlap = ( buf_size - buffer_start ); new_size = buf_size + buffer_size - overlap; alloc_size = ( s -> buffer_size > new_size ? s -> buffer_size : new_size ); if ( alloc_size > buf_size )  if ( ! ( buf = * bufp = ( av_realloc_f ( buf , 1 , alloc_size ) ) ) )  if ( new_size > buf_size )  memcpy ( ( buf + buf_size ) , ( s -> buffer + overlap ) , ( buffer_size - overlap ) ); s -> buf_ptr = s -> buffer = buf; s -> buffer_size = alloc_size; s -> pos = buf_size; s -> buf_end = s -> buf_ptr + buf_size; s -> eof_reached = 0; s -> must_flush = 0; 