R_API int r_anal_xrefs_deln (RAnal *anal, const RAnalRefType type, ut64 from, ut64 to) { char key[33]; if (!anal || !DB) { return false; } XREFKEY (key, sizeof (key), "ref", type, from); sdb_array_remove_num (DB, key, to, 0); XREFKEY (key, sizeof (key), "xref", type, to); sdb_array_remove_num (DB, key, from, 0); return true; }
static int meta_inrange_del (RAnal *a, ut64 addr, int size) { int set = 0; char key[64]; ut64 base, base2; base = META_RANGE_BASE (addr); base2 = META_RANGE_BASE (addr+size); // TODO: optimize this thing? for (; base<base2; base += META_RANGE_SIZE) { snprintf (key, sizeof (key)-1, "range.0x%"PFMT64x, base); if (sdb_array_remove_num (DB, key, addr, 0)) set = 1; } //sdb_array_del (DB); return set; }