Make afij ref-types more readable for human animals ##anal

This commit is contained in:
Itay Cohen 2019-01-16 23:19:47 +02:00 committed by radare
parent 51ed856b67
commit a3058427f1

View File

@ -2368,10 +2368,10 @@ static int fcn_print_json(RCore *core, RAnalFunction *fcn) {
}
if (refi->type == R_ANAL_REF_TYPE_CODE ||
refi->type == R_ANAL_REF_TYPE_CALL) {
r_cons_printf ("%s{\"addr\":%"PFMT64d",\"type\":\"%c\",\"at\":%"PFMT64d"}",
r_cons_printf ("%s{\"addr\":%"PFMT64d",\"type\":\"%s\",\"at\":%"PFMT64d"}",
first? "": ",",
refi->addr,
refi->type == R_ANAL_REF_TYPE_CALL?'C':'J',
r_anal_xrefs_type_tostring (refi->type),
refi->at);
first = false;
}
@ -2399,10 +2399,10 @@ static int fcn_print_json(RCore *core, RAnalFunction *fcn) {
if (refi->type == R_ANAL_REF_TYPE_CODE ||
refi->type == R_ANAL_REF_TYPE_CALL) {
indegree++;
r_cons_printf ("%s{\"addr\":%"PFMT64d",\"type\":\"%c\",\"at\":%"PFMT64d"}",
r_cons_printf ("%s{\"addr\":%"PFMT64d",\"type\":\"%s\",\"at\":%"PFMT64d"}",
first?"":",",
refi->addr,
refi->type==R_ANAL_REF_TYPE_CALL?'C':'J',
r_anal_xrefs_type_tostring (refi->type),
refi->at);
first = 0;
}