mirror of
https://github.com/radareorg/radare2.git
synced 2025-02-21 06:40:33 +00:00
rework =!qRcmd to more intuitive =!monitor, send monitor help by default (#8081)
This commit is contained in:
parent
5da2238b7b
commit
579a043b87
@ -200,8 +200,8 @@ static int __system(RIO *io, RIODesc *fd, const char *cmd) {
|
||||
eprintf ("Usage: =!cmd args\n"
|
||||
" =!pid - show targeted pid\n"
|
||||
" =!pkt s - send packet 's'\n"
|
||||
" =!qRcmd cmd - hex-encode cmd and pass to target"
|
||||
" interpreter\n"
|
||||
" =!monitor cmd - hex-encode monitor command and pass"
|
||||
" to target interpreter\n"
|
||||
" =!inv.reg - invalidate reg cache\n"
|
||||
" =!pktsz - get max packet size used\n"
|
||||
" =!pktsz bytes - set max. packet size as 'bytes' bytes\n"
|
||||
@ -243,8 +243,12 @@ static int __system(RIO *io, RIODesc *fd, const char *cmd) {
|
||||
}
|
||||
return pid;
|
||||
}
|
||||
if (!strncmp (cmd, "qRcmd ", 6)) {
|
||||
if (gdbr_send_qRcmd (desc, cmd + 6) < 0) {
|
||||
if (!strncmp (cmd, "monitor", 7)) {
|
||||
const char *qrcmd = cmd + 8;
|
||||
if (!isspace (cmd[8])) {
|
||||
qrcmd = "help";
|
||||
}
|
||||
if (gdbr_send_qRcmd (desc, qrcmd) < 0) {
|
||||
eprintf ("remote error\n");
|
||||
return false;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user