mirror of
https://github.com/radareorg/radare2.git
synced 2025-02-27 01:26:07 +00:00
search.maxhits is more aggressive now
This commit is contained in:
parent
17e6746f59
commit
1638507d01
@ -1189,8 +1189,7 @@ static int r_core_search_rop(RCore *core, RAddrInterval search_itv, int opt, con
|
||||
const char *smode = r_config_get (core->config, "search.in");
|
||||
const char *arch = r_config_get (core->config, "asm.arch");
|
||||
ut64 from = search_itv.addr, to = r_itv_end (search_itv);
|
||||
// int max_count = core->search->maxhits;
|
||||
int max_count = r_config_get_i (core->config, "search.maxhits"); // core->search->maxhits
|
||||
int max_count = r_config_get_i (core->config, "search.maxhits");
|
||||
int i = 0, end = 0, mode = 0, increment = 1, ret;
|
||||
RList /*<endlist_pair>*/ *end_list = r_list_newf (free);
|
||||
RList /*<intptr_t>*/ *badstart = r_list_new ();
|
||||
@ -1915,7 +1914,7 @@ static void do_anal_search(RCore *core, struct search_parameters *param, const c
|
||||
}
|
||||
count++;
|
||||
if (search->maxhits && count >= search->maxhits) {
|
||||
break;
|
||||
goto done;
|
||||
}
|
||||
firstItem = false;
|
||||
}
|
||||
@ -1928,6 +1927,7 @@ static void do_anal_search(RCore *core, struct search_parameters *param, const c
|
||||
}
|
||||
}
|
||||
}
|
||||
done:
|
||||
if (mode == 'j') {
|
||||
r_cons_println ("]\n");
|
||||
}
|
||||
|
@ -354,8 +354,8 @@ static int cmd_seek(void *data, const char *input) {
|
||||
case '/': // "s/"
|
||||
{
|
||||
const char *pfx = r_config_get (core->config, "search.prefix");
|
||||
const ut64 saved_from = r_config_get_i (core->config, "search.from"),
|
||||
saved_maxhits = r_config_get_i (core->config, "search.maxhits");
|
||||
const ut64 saved_from = r_config_get_i (core->config, "search.from");
|
||||
const ut64 saved_maxhits = r_config_get_i (core->config, "search.maxhits");
|
||||
// kwidx cfg var is ignored
|
||||
int kwidx = core->search->n_kws; // (int)r_config_get_i (core->config, "search.kwidx")-1;
|
||||
if (kwidx < 0) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user