mirror of
https://github.com/radareorg/radare2.git
synced 2024-12-14 00:38:55 +00:00
Fix #5729 - tk uses rcons now
This commit is contained in:
parent
17c3d30a47
commit
ae511391e2
@ -155,29 +155,31 @@ static int typelist (void *p, const char *k, const char *v) {
|
|||||||
|
|
||||||
static int cmd_type(void *data, const char *input) {
|
static int cmd_type(void *data, const char *input) {
|
||||||
RCore *core = (RCore *)data;
|
RCore *core = (RCore *)data;
|
||||||
|
char *res;
|
||||||
|
const char *help_message[] = {
|
||||||
|
"USAGE tu[...]", "", "",
|
||||||
|
"tu", "", "List all loaded unions",
|
||||||
|
"tu?", "", "show this help",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
||||||
switch (input[0]) {
|
switch (input[0]) {
|
||||||
// t [typename] - show given type in C syntax
|
// t [typename] - show given type in C syntax
|
||||||
case 'u': // "tu"
|
case 'u': // "tu"
|
||||||
switch (input[1]) {
|
switch (input[1]) {
|
||||||
case '?': {
|
case '?':
|
||||||
const char *help_message[] = {
|
|
||||||
"USAGE tu[...]", "", "",
|
|
||||||
"tu", "", "List all loaded unions",
|
|
||||||
"tu?", "", "show this help",
|
|
||||||
NULL };
|
|
||||||
r_core_cmd_help (core, help_message);
|
r_core_cmd_help (core, help_message);
|
||||||
} break;
|
break;
|
||||||
case 0:
|
case 0:
|
||||||
sdb_foreach (core->anal->sdb_types, stdprintifunion, core);
|
sdb_foreach (core->anal->sdb_types, stdprintifunion, core);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 'k': // "tk"
|
case 'k': // "tk"
|
||||||
if (input[1] == ' ') {
|
res = (input[1] == ' ')
|
||||||
sdb_query (core->anal->sdb_types, input + 2);
|
? sdb_querys (core->anal->sdb_types, NULL, -1, input + 2)
|
||||||
} else sdb_query (core->anal->sdb_types, "*");
|
: sdb_querys (core->anal->sdb_types, NULL, -1, "*");
|
||||||
fflush (stdout);
|
r_cons_println (res);
|
||||||
break;
|
break;
|
||||||
case 's': // "ts"
|
case 's': // "ts"
|
||||||
switch (input[1]) {
|
switch (input[1]) {
|
||||||
|
Loading…
Reference in New Issue
Block a user