Reimplement s++/s-- in empty cmd using the API instead of rcorecmd()
This commit is contained in:
parent
ff5de06cc7
commit
08c366e6e5
1 changed files with 9 additions and 1 deletions
|
|
@ -1825,7 +1825,15 @@ R_API void r_core_cmd_repeat(RCore *core, int next) {
|
|||
case 'p': // print
|
||||
case 'x':
|
||||
case '$':
|
||||
r_core_cmd0 (core, next? "s++": "s--");
|
||||
if (next) {
|
||||
r_core_seek (core, core->offset + core->blocksize, 1);
|
||||
} else {
|
||||
if (core->blocksize > core->offset) {
|
||||
r_core_seek (core, 0, 1);
|
||||
} else {
|
||||
r_core_seek (core, core->offset - core->blocksize, 1);
|
||||
}
|
||||
}
|
||||
r_core_cmd0 (core, core->lastcmd);
|
||||
break;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue