static void * load_bytes(const ut8 *buf, ut64 sz, ut64 loadaddr, Sdb *sdb){ void *res = NULL; RBuffer *tbuf = NULL; if (!buf || sz == 0 || sz == UT64_MAX) return NULL; tbuf = r_buf_new (); r_buf_set_bytes (tbuf, buf, sz); res = r_bin_dex_new_buf (tbuf); r_buf_free (tbuf); return res; }
static int load(RBinArch *arch) { if(!(arch->bin_obj = r_bin_dex_new_buf(arch->buf))) return R_FALSE; return R_TRUE; }
static int load(RBinArch *arch) { arch->bin_obj = r_bin_dex_new_buf (arch->buf); return arch->bin_obj ? R_TRUE: R_FALSE; }