Rizin
unix-like reverse engineering framework and cli tools
|
Go to the source code of this file.
Classes | |
struct | Filetable |
Macros | |
#define | AR_MAGIC_HEADER "!<arch>\n" |
#define | AR_FILE_HEADER_END "`\n" |
#define | VERIFY_AR_NUM_FIELD(x, s) |
Typedefs | |
typedef struct Filetable | filetable |
Functions | |
static RzArFp * | arfp_new (RzBuffer *b, bool shared_buf) |
bool | ar_check_magic (RzBuffer *b) |
static void | arf_clean_name (RzArFp *arf) |
static char * | name_from_table (ut64 off, filetable *tbl) |
static int | ar_parse_header (RzArFp *arf, filetable *tbl, ut64 arsize) |
RZ_API RzList * | ar_open_all (const char *arname, int perm) |
Open specific file withen a ar/lib file. More... | |
RZ_API RzArFp * | ar_open_file (const char *arname, int perm, const char *filename) |
Open specific file withen a ar/lib file. More... | |
RZ_API void | ar_close (RzArFp *f) |
RZ_API int | ar_read_at (RzArFp *f, ut64 off, void *buf, int count) |
RZ_API int | ar_write_at (RzArFp *f, ut64 off, void *buf, int count) |
Definition at line 28 of file ar.c.
References AR_MAGIC_HEADER, b, rz_buf_read(), and RZ_LOG_ERROR.
Referenced by ar_open_all(), and ar_open_file().
Definition at line 338 of file ar.c.
References f, free(), and rz_buf_free().
Referenced by ar_open_all(), ar_open_file(), and rz_io_ar_close().
Open specific file withen a ar/lib file.
arname | the name of the .a file |
Open an ar/lib and returns all the object files inside it.
Definition at line 218 of file ar.c.
References ar_check_magic(), ar_close(), ar_parse_header(), arfp_new(), b, Filetable::data, files, free(), NULL, rz_buf_free(), rz_buf_new_file(), rz_buf_size(), rz_list_append(), rz_list_free(), rz_list_newf(), rz_sys_perror, and ut64().
Referenced by rz_io_ar_open_many().
Open specific file withen a ar/lib file.
arname | the name of the .a file |
filename | the name of file in the .a file that you wish to open |
Open an ar/lib file by name.
Definition at line 286 of file ar.c.
References ar_check_magic(), ar_close(), ar_parse_header(), arf_clean_name(), arfp_new(), b, Filetable::data, free(), RZARFP::name, NULL, r, rz_buf_free(), rz_buf_new_file(), rz_buf_size(), RZ_LOG_ERROR, rz_sys_perror, and ut64().
Referenced by rz_io_ar_open().
Definition at line 76 of file ar.c.
References AR_FILE_HEADER_END, arf_clean_name(), b, RZARFP::buf, Filetable::data, test_evm::end, RZARFP::end, free(), h, header, list(), malloc(), RZARFP::name, name_from_table(), Filetable::offset, PFMT64x, r, RZ_BUF_CUR, rz_buf_read(), rz_buf_seek(), rz_buf_tell(), rz_list_free(), rz_list_length(), rz_list_pop(), rz_list_pop_head(), RZ_LOG_ERROR, rz_return_val_if_fail, rz_str_isnumber(), rz_str_split_duplist(), rz_str_trim_tail(), Filetable::size, RZARFP::start, autogen_x86imm::tmp, ut64(), and VERIFY_AR_NUM_FIELD.
Referenced by ar_open_all(), and ar_open_file().
Definition at line 349 of file ar.c.
References count, f, off, and rz_buf_read_at().
Referenced by rz_io_ar_read().
Definition at line 360 of file ar.c.
References count, f, off, and rz_buf_write_at().
Referenced by rz_io_ar_write().
|
inlinestatic |
Definition at line 40 of file ar.c.
References free(), RZARFP::name, and NULL.
Referenced by ar_open_file(), and ar_parse_header().
Definition at line 15 of file ar.c.
References b, f, NULL, RZ_NEW, and rz_return_val_if_fail.
Referenced by ar_open_all(), and ar_open_file().
Definition at line 45 of file ar.c.
References c, Filetable::data, i, NULL, off, PFMT64x, RZ_LOG_ERROR, rz_str_newlen(), Filetable::size, and ut64().
Referenced by ar_parse_header().