mirror of
https://github.com/radareorg/radare2.git
synced 2025-01-31 10:22:37 +00:00
Fix a bunch of dead assignements
This commit is contained in:
parent
9e11c5ce63
commit
d4893718da
@ -169,3 +169,4 @@ It's the year of desktop on radare2
|
||||
It's the year of radare2 on the desktop
|
||||
SSAbotage from ISIL
|
||||
"a collection of garbage" -- an r2 pro user
|
||||
A git pull a day keeps the segfault away
|
||||
|
@ -8,9 +8,8 @@
|
||||
static int analop(RAnal *a, RAnalOp *op, ut64 addr, const ut8 *buf, int len) {
|
||||
csh handle;
|
||||
cs_insn *insn;
|
||||
int mode = (a->bits==64)? CS_MODE_64:
|
||||
(a->bits==32)? CS_MODE_32: 0;
|
||||
mode = CS_MODE_BIG_ENDIAN;
|
||||
int mode = (a->bits==64)? CS_MODE_64: (a->bits==32)? CS_MODE_32: 0;
|
||||
mode |= CS_MODE_BIG_ENDIAN;
|
||||
int n, ret = cs_open (CS_ARCH_PPC, mode, &handle);
|
||||
op->delay = 0;
|
||||
op->type = R_ANAL_OP_TYPE_NULL;
|
||||
|
@ -491,14 +491,13 @@ static void get_method_list_t (mach0_ut p,
|
||||
|
||||
method->vaddr = m.imp;
|
||||
|
||||
struct MACH0_(obj_t) *bin = (struct MACH0_(obj_t) *) arch->o->bin_obj;
|
||||
if (is_thumb (arch)) {
|
||||
if (method->vaddr & 1) {
|
||||
method->vaddr >>= 1;
|
||||
method->vaddr <<= 1;
|
||||
//eprintf ("0x%08llx METHOD %s\n", method->vaddr, method->name);
|
||||
}
|
||||
if (is_thumb (arch)) {
|
||||
if (method->vaddr & 1) {
|
||||
method->vaddr >>= 1;
|
||||
method->vaddr <<= 1;
|
||||
//eprintf ("0x%08llx METHOD %s\n", method->vaddr, method->name);
|
||||
}
|
||||
}
|
||||
|
||||
r_list_append (processed_class->methods, method);
|
||||
|
||||
|
@ -597,17 +597,16 @@ static int cmd_write(void *data, const char *input) {
|
||||
eprintf ("TODO\n");
|
||||
} else if (input[2]==' ') {
|
||||
char *p = strchr (input+3, ' ');
|
||||
ut64 to, from = core->offset;
|
||||
ut64 to, from;
|
||||
from = r_num_math (core->num, input+3);
|
||||
if (p) {
|
||||
*p = 0;
|
||||
from = r_num_math (core->num, input+3);
|
||||
to = r_num_math (core->num, input+3);
|
||||
if (to<from) {
|
||||
eprintf ("Invalid range (from>to)\n");
|
||||
return 0;
|
||||
}
|
||||
} else {
|
||||
from = r_num_math (core->num, input+3);
|
||||
to = from + core->blocksize;
|
||||
}
|
||||
r_io_cache_commit (core->io, from, to);
|
||||
|
@ -399,7 +399,7 @@ static void handle_reflines_update (RAnal *anal, RDisasmState *ds) {
|
||||
RAnalRefline *ref;
|
||||
int maxlen = 512;
|
||||
int maxlines = 100;
|
||||
int delta = ds->at - ds->addr;
|
||||
int delta;
|
||||
if (lastaddr == UT64_MAX) {
|
||||
lastaddr = ds->addr;
|
||||
}
|
||||
|
@ -752,7 +752,7 @@ static int r_cmd_java_get_class_names_from_input (const char *input, char **clas
|
||||
*class_name_len = 0;
|
||||
|
||||
if (p && *p && cmd_sz > 1) {
|
||||
const char *end = p;
|
||||
const char *end;
|
||||
p = r_cmd_java_consumetok (p, ' ', cmd_sz);
|
||||
end = p && *p ? r_cmd_java_strtok (p, ' ', -1) : NULL;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user