mirror of
https://github.com/radareorg/radare2.git
synced 2024-12-11 15:04:23 +00:00
Leak "so" command (#8650)
This commit is contained in:
parent
de35a3fb8d
commit
f8d71b8ded
@ -626,7 +626,6 @@ static int cmd_seek(void *data, const char *input) {
|
|||||||
}
|
}
|
||||||
case 'o': // "so"
|
case 'o': // "so"
|
||||||
{
|
{
|
||||||
RAnalOp op;
|
|
||||||
int val = 0, ret, i, n = r_num_math (core->num, input + 1);
|
int val = 0, ret, i, n = r_num_math (core->num, input + 1);
|
||||||
if (n == 0) {
|
if (n == 0) {
|
||||||
n = 1;
|
n = 1;
|
||||||
@ -644,12 +643,15 @@ static int cmd_seek(void *data, const char *input) {
|
|||||||
val += ret;
|
val += ret;
|
||||||
} else {
|
} else {
|
||||||
for (val = i = 0; i < n; i++) {
|
for (val = i = 0; i < n; i++) {
|
||||||
|
RAnalOp op;
|
||||||
|
|
||||||
ret = r_anal_op (core->anal, &op,
|
ret = r_anal_op (core->anal, &op,
|
||||||
core->offset, core->block, core->blocksize);
|
core->offset, core->block, core->blocksize);
|
||||||
if (ret < 1) {
|
if (ret < 1) {
|
||||||
ret = 1;
|
ret = 1;
|
||||||
}
|
}
|
||||||
r_core_seek_delta (core, ret);
|
r_core_seek_delta (core, ret);
|
||||||
|
r_anal_op_fini (&op);
|
||||||
val += ret;
|
val += ret;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user