Language: Go
Label: vulnerable
CWE: CWE-787 \u2014 Out-of-bounds Write
The product writes data past the end, or before the beginning, of the intended buffer.

Code:
static void axfm(RCore *core) {
	RVecAnalRef *refs = r_anal_xrefs_get_from (core->anal, UT64_MAX);
	if (refs && !RVecAnalRef_empty (refs)) {
		RVecAnalRef_sort (refs, compare_ref);

		ut64 last_addr = UT64_MAX;
		RAnalRef *ref;
		R_VEC_FOREACH (refs, ref) {
			const bool is_first = ref->addr != last_addr;
			const char *name;
			if (is_first) {
				name = axtm_name (core, ref->addr);
				r_cons_printf ("0x%"PFMT64x": %s\n", ref->addr, name? name: "?");
			}

			name = axtm_name (core, ref->at);
			r_cons_printf ("  0x%"PFMT64x": %s\n", ref->at, name? name: "?");

			last_addr = ref->addr;
		}
	}

	RVecAnalRef_free (refs);
}