MCPcopy Create free account
hub / github.com/HandBrake/HandBrake / hb_data_init

Function hb_data_init

libhb/common.c:4388–4408  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4386}
4387
4388hb_data_t * hb_data_init(size_t size)
4389{
4390 hb_data_t *data = av_mallocz(sizeof(hb_data_t));
4391 if (data == NULL)
4392 {
4393 goto fail;
4394 }
4395
4396 data->bytes = av_mallocz(size);
4397 if (data->bytes == NULL)
4398 {
4399 goto fail;
4400 }
4401
4402 data->size = size;
4403 return data;
4404
4405fail:
4406 hb_data_close(&data);
4407 return NULL;
4408}
4409
4410void hb_data_close(hb_data_t **data)
4411{

Callers 5

hb_data_dupFunction · 0.85
copy_frameFunction · 0.85
hb_set_extradataFunction · 0.85
hb_set_h264_extradataFunction · 0.85
hb_set_xiph_extradataFunction · 0.85

Calls 1

hb_data_closeFunction · 0.85

Tested by

no test coverage detected