Eina_Binbuf *out;
Eina_Binbuf *in;
- in = eina_binbuf_manage_read_only_new_length(data, size);
+ in = eina_binbuf_manage_new(data, size, EINA_TRUE);
out = emile_binbuf_cipher(EMILE_AES256_CBC, in, key, length);
if (result_length) *result_length = out ? eina_binbuf_length_get(out) : 0;
Eina_Binbuf *out;
Eina_Binbuf *in;
- in = eina_binbuf_manage_read_only_new_length(data, size);
+ in = eina_binbuf_manage_new(data, size, EINA_TRUE);
out = emile_binbuf_decipher(EMILE_AES256_CBC, in, key, length);
if (result_length) *result_length = out ? eina_binbuf_length_get(out) : 0;
Emile_Image_Load_Error error;
int r = 0;
- bin = eina_binbuf_manage_read_only_new_length(data, size);
+ bin = eina_binbuf_manage_new(data, size, EINA_TRUE);
if (!bin) return 0;
memset(&opts, 0, sizeof (Emile_Image_Load_Opts));
// Fix for ABI incompatibility between 1.10 and 1.11
if (cspace == 8) cspace = 9;
- bin = eina_binbuf_manage_read_only_new_length(data, size);
+ bin = eina_binbuf_manage_new(data, size, EINA_TRUE);
if (!bin) return 0;
memset(&opts, 0, sizeof (Emile_Image_Load_Opts));
if (!pixels)
return 0;
- bin = eina_binbuf_manage_read_only_new_length(data, size);
+ bin = eina_binbuf_manage_new(data, size, EINA_TRUE);
if (!bin) return 0;
memset(&opts, 0, sizeof (Emile_Image_Load_Opts));
// Fix for ABI incompatibility between 1.10 and 1.11
if (cspace == 8) cspace = 9;
- bin = eina_binbuf_manage_read_only_new_length(data, length);
+ bin = eina_binbuf_manage_new(data, length, EINA_TRUE);
if (!bin) return 0;
memset(&opts, 0, sizeof (Emile_Image_Load_Opts));
data = (const char *) bigend_data;
}
- in = eina_binbuf_manage_read_only_new_length(data, w * h * 4);
+ in = eina_binbuf_manage_new(data, w * h * 4, EINA_TRUE);
if (!in)
{
free(bigend_data);
}
}
- in = eina_binbuf_manage_read_only_new_length(buffer, block_count * etc_block_size);
+ in = eina_binbuf_manage_new(buffer, block_count * etc_block_size, EINA_TRUE);
if (compress)
{
Eina_Binbuf *out;
Eina_Binbuf *in;
Eina_Binbuf *out;
- in = eina_binbuf_manage_read_only_new_length((const unsigned char *) body, size - 8 * sizeof (int));
+ in = eina_binbuf_manage_new((const unsigned char *) body, size - 8 * sizeof (int), EINA_TRUE);
if (!in) return 0;
if ((src_h == h) && (src_w == w) && (row_stride == src_w * 4))
{
- out = eina_binbuf_manage_read_only_new_length((void*) d,
- w * h * 4);
+ out = eina_binbuf_manage_new((void*) d, w * h * 4, EINA_TRUE);
if (!emile_expand(in, out,
eet_2_emile_compressor(comp)))
{
/* figure hash bucket */
hash = _eet_hash_gen(name, ef->header->directory->size);
- in = eina_binbuf_manage_read_only_new_length((unsigned char*) destination, strlen(destination) + 1);
+ in = eina_binbuf_manage_new((unsigned char*) destination, strlen(destination) + 1, EINA_TRUE);
if (!in) goto on_error;
/* if we want to compress */
UNLOCK_FILE(ef);
- in = eina_binbuf_manage_read_only_new_length(data, size);
+ in = eina_binbuf_manage_new(data, size, EINA_TRUE);
if (comp)
{
Eina_Binbuf *out;
Eet_File_Node *efn)
{
if (efn->data)
- return eina_binbuf_manage_read_only_new_length(efn->data, efn->size);
+ return eina_binbuf_manage_new(efn->data, efn->size, EINA_TRUE);
if (efn->offset > ef->data_size)
return 0;
if ((efn->offset + efn->size) > ef->data_size)
return 0;
- return eina_binbuf_manage_read_only_new_length(ef->data + efn->offset, efn->size);
+ return eina_binbuf_manage_new(ef->data + efn->offset, efn->size, EINA_TRUE);
}