mirror of
https://github.com/radareorg/radare2.git
synced 2025-01-24 06:48:46 +00:00
Handle 'ph?'
This commit is contained in:
parent
ab1e0de94c
commit
8909464c45
@ -264,6 +264,13 @@ static const char *help_msg_pdp[] = {
|
||||
NULL
|
||||
};
|
||||
|
||||
static const char *help_msg_ph[] = {
|
||||
"Usage:", "ph", " [algorithm] ([size])",
|
||||
"ph", " md5", "compute md5 hash of current block",
|
||||
"ph.", " sha1 32 @ 0x1000", "calculate sha1 of 32 bytes starting at 0x1000",
|
||||
NULL
|
||||
};
|
||||
|
||||
static const char *help_msg_pdr[] = {
|
||||
"Usage:", "pdr", "Disassemble N instructions following execution flow from current PC",
|
||||
"pdr", "", "recursive disassemble across the function graph",
|
||||
@ -2906,7 +2913,11 @@ static bool cmd_print_ph(RCore *core, const char *input) {
|
||||
const char *ptr;
|
||||
int pos = 0, handled_cmd = false;
|
||||
|
||||
if (!*input || *input == '?') {
|
||||
if (*input == '?') {
|
||||
r_core_cmd_help (core, help_msg_ph);
|
||||
return true;
|
||||
}
|
||||
if (!*input) {
|
||||
algolist (1);
|
||||
return true;
|
||||
}
|
||||
|
@ -2119,7 +2119,7 @@ static void cmd_search_aF(RCore *core, const char *input) {
|
||||
}
|
||||
r_str_trim (s);
|
||||
if (strstr (s, input)) {
|
||||
eprintf ("0x%08"PFMT64x" %s: %s\n", addr, fcn->name, s);
|
||||
r_cons_printf ("0x%08"PFMT64x" %s: %s\n", addr, fcn->name, s);
|
||||
}
|
||||
free (s);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user