diff options
author | comex | 2015-01-21 17:02:52 -0500 |
---|---|---|
committer | comex | 2015-01-21 17:03:21 -0500 |
commit | 9fbf8080fb308d9c6dad8c534ad8892c2d715087 (patch) | |
tree | 3415053faf262f7ad2766d18c0885d81ba7cbad2 /test/test-jump-dis.c | |
parent | forgot to actually check this in (diff) | |
download | substitute-9fbf8080fb308d9c6dad8c534ad8892c2d715087.tar.gz |
minor cleanup - stop caring about thumb outside of arch-specific code
(and fix makefile bug where files whose names contained 'arm' would
always be ldid'd)
Diffstat (limited to 'test/test-jump-dis.c')
-rw-r--r-- | test/test-jump-dis.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/test/test-jump-dis.c b/test/test-jump-dis.c index 1a34bc0..ef6add8 100644 --- a/test/test-jump-dis.c +++ b/test/test-jump-dis.c @@ -7,7 +7,12 @@ int main(UNUSED int argc, char **argv) { UNUSED size_t size = fread(buf, 1, sizeof(buf), stdin); printf("size=%zd\n", size); int patch_size = atoi(argv[1]); + struct arch_dis_ctx arch; + memset(&arch, 0, sizeof(arch)); +#ifdef __arm__ int thumb = atoi(argv[2]); - bool bad = P(main)(buf, 0x10000, 0x10000 + patch_size, thumb); + arch.pc_low_bit = thumb; +#endif + bool bad = P(main)(buf, 0x10000, 0x10000 + patch_size, arch); printf("final: bad = %d\n", bad); } |