Rizin
unix-like reverse engineering framework and cli tools
|
Go to the source code of this file.
zip_extra_field_t* _zip_ef_clone | ( | const zip_extra_field_t * | ef, |
zip_error_t * | error | ||
) |
Definition at line 41 of file zip_extra_field.c.
References _zip_ef_free(), _zip_ef_new(), ef::data, def(), error(), ef::flags, test-lz4-versions::head, ef::id, zip_extra_field::next, NULL, ef::size, ZIP_ER_MEMORY, and zip_error_set().
Referenced by _zip_file_extra_field_prepare_for_change().
zip_extra_field_t* _zip_ef_delete_by_id | ( | zip_extra_field_t * | ef, |
zip_uint16_t | id, | ||
zip_uint16_t | id_idx, | ||
zip_flags_t | flags | ||
) |
Definition at line 67 of file zip_extra_field.c.
References _zip_ef_free(), ef, flags, ef::flags, test-lz4-versions::head, i, id, ef::id, zip_extra_field::next, NULL, ZIP_EF_BOTH, and ZIP_EXTRA_FIELD_ALL.
Referenced by zip_file_extra_field_delete(), and zip_file_extra_field_delete_by_id().
void _zip_ef_free | ( | zip_extra_field_t * | ef | ) |
Definition at line 103 of file zip_extra_field.c.
References ef::data, and free().
Referenced by _zip_dirent_finalize(), _zip_dirent_write(), _zip_ef_clone(), _zip_ef_delete_by_id(), _zip_ef_merge(), _zip_ef_parse(), _zip_ef_remove_internal(), and zip_file_extra_field_set().
const zip_uint8_t* _zip_ef_get_by_id | ( | const zip_extra_field_t * | ef, |
zip_uint16_t * | lenp, | ||
zip_uint16_t | id, | ||
zip_uint16_t | id_idx, | ||
zip_flags_t | flags, | ||
zip_error_t * | error | ||
) |
Definition at line 116 of file zip_extra_field.c.
References ef::data, ef, error(), flags, ef::flags, i, ef::id, NULL, ef::size, ZIP_EF_BOTH, ZIP_ER_NOENT, and zip_error_set().
Referenced by _zip_dirent_process_ef_utf_8(), _zip_dirent_process_winzip_aes(), _zip_dirent_read(), and zip_file_extra_field_get_by_id().
zip_extra_field_t* _zip_ef_merge | ( | zip_extra_field_t * | to, |
zip_extra_field_t * | from | ||
) |
Definition at line 144 of file zip_extra_field.c.
References _zip_ef_free(), zip_extra_field::data, zip_extra_field::flags, from, zip_extra_field::id, zip_extra_field::next, NULL, zip_extra_field::size, to, and ZIP_EF_BOTH.
Referenced by _zip_checkcons(), and _zip_read_local_ef().
zip_extra_field_t* _zip_ef_new | ( | zip_uint16_t | id, |
zip_uint16_t | size, | ||
const zip_uint8_t * | data, | ||
zip_flags_t | flags | ||
) |
Definition at line 178 of file zip_extra_field.c.
References _zip_memdup(), ef::data, ef, flags, ef::flags, free(), id, ef::id, malloc(), NULL, and ef::size.
Referenced by _zip_dirent_write(), _zip_ef_clone(), _zip_ef_parse(), _zip_ef_utf8(), and zip_file_extra_field_set().
bool _zip_ef_parse | ( | const zip_uint8_t * | data, |
zip_uint16_t | len, | ||
zip_flags_t | flags, | ||
zip_extra_field_t ** | ef_head_p, | ||
zip_error_t * | error | ||
) |
Definition at line 202 of file zip_extra_field.c.
References _zip_buffer_eof(), _zip_buffer_free(), _zip_buffer_get(), _zip_buffer_get_16(), _zip_buffer_left(), _zip_buffer_new(), _zip_buffer_ok(), _zip_ef_free(), _zip_ef_new(), ef, error(), flags, len, NULL, ZIP_ER_DETAIL_EF_TRAILING_GARBAGE, ZIP_ER_DETAIL_INVALID_EF_LENGTH, ZIP_ER_INCONS, ZIP_ER_MEMORY, and zip_error_set().
Referenced by _zip_dirent_read(), and _zip_read_local_ef().
zip_extra_field_t* _zip_ef_remove_internal | ( | zip_extra_field_t * | ef | ) |
Definition at line 271 of file zip_extra_field.c.
References _zip_ef_free(), ef, ef::id, zip_extra_field::next, NULL, and ZIP_EF_IS_INTERNAL.
Referenced by _zip_dirent_read(), and _zip_read_local_ef().
zip_uint16_t _zip_ef_size | ( | const zip_extra_field_t * | ef, |
zip_flags_t | flags | ||
) |
Definition at line 300 of file zip_extra_field.c.
References ef, flags, ef::flags, ef::size, and ZIP_EF_BOTH.
Referenced by _zip_dirent_write(), and zip_file_extra_field_set().
int _zip_ef_write | ( | zip_t * | za, |
const zip_extra_field_t * | ef, | ||
zip_flags_t | flags | ||
) |
Definition at line 314 of file zip_extra_field.c.
References _zip_buffer_free(), _zip_buffer_new(), _zip_buffer_ok(), _zip_buffer_put_16(), _zip_buffer_set_offset(), _zip_write(), b, ef::data, ef, zip::error, flags, ef::flags, ef::id, NULL, ef::size, za, ZIP_EF_BOTH, ZIP_ER_INTERNAL, and zip_error_set().
Referenced by _zip_dirent_write().
int _zip_read_local_ef | ( | zip_t * | za, |
zip_uint64_t | idx | ||
) |
Definition at line 351 of file zip_extra_field.c.
References _zip_buffer_eof(), _zip_buffer_free(), _zip_buffer_get_16(), _zip_buffer_new_from_source(), _zip_ef_merge(), _zip_ef_parse(), _zip_ef_remove_internal(), _zip_error_set_from_source(), _zip_read_data(), b, e, ef, EFBIG, zip::entry, zip::error, free(), setup::idx, zip::nentry, NULL, SEEK_CUR, SEEK_SET, zip::src, za, ZIP_EF_LOCAL, ZIP_ER_INTERNAL, ZIP_ER_INVAL, ZIP_ER_SEEK, zip_error_set(), ZIP_INT64_MAX, and zip_source_seek().
Referenced by _zip_file_extra_field_prepare_for_change(), zip_close(), zip_file_extra_field_get(), zip_file_extra_field_get_by_id(), zip_file_extra_fields_count(), and zip_file_extra_fields_count_by_id().