From acc7a2543dd10846718f0c9a4e1f5213b977c311 Mon Sep 17 00:00:00 2001 From: radare Date: Mon, 31 Dec 2018 00:22:33 +0100 Subject: [PATCH] Use add-sorted instead of append+sort ##anal --- libr/core/canal.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/libr/core/canal.c b/libr/core/canal.c index 86ec4bbd61..a9ec1f1f95 100644 --- a/libr/core/canal.c +++ b/libr/core/canal.c @@ -775,8 +775,7 @@ static int core_anal_fcn(RCore *core, ut64 at, ut64 from, int reftype, int depth if (!f->fcn_locs) { f->fcn_locs = r_list_new (); } - r_list_append (f->fcn_locs, fcn); - r_list_sort (f->fcn_locs, &cmpfcn); + r_list_add_sorted (f->fcn_locs, fcn, &cmpfcn); } } r_anal_xrefs_set (core->anal, from, fcn->addr, reftype);