Commit Graph

296 Commits

Author SHA1 Message Date
pancake
87e812e86c Implement drc k=v to set conditional flags by type ##debug 2019-04-24 11:47:00 +02:00
radare
ad3689b34d
Add the ability to set some registers readonly ##anal 2019-04-14 21:04:56 +02:00
Anton Kochkov
bb67b54f74
Remove CYGWIN & MINGW remnants (#13377) 2019-03-15 12:55:08 +08:00
radare
0a6ff520cb
Fix #13326 - Implement of asm.regsub to replace register names with their role alias ##disasm (#13330) 2019-03-09 10:21:04 +01:00
radare
cdbe9dff2d
Implement aeC (ESIL appcall), also drr shows reg aliases and add dr?? ##debug (#12997) 2019-02-04 19:27:30 -06:00
pancake
6c2d945272 Fix aht cjmp and optimize assert in asm.emu when no regprofile is set ##anal 2019-01-20 12:16:47 +01:00
lzutao
1365948cee Do not use reversed keyword of meson ##build
`files` is a reversed keyword in meson. Try to avoid using it.
2019-01-10 14:15:50 +01:00
lzutao
9cc6d2d291 meson: Do not use glob with meson ##build
* meson: Explicit is better than implicit
* meson: Fix deprecated warnings in Meson 0.49.0
* meson: Do not need separate array for installed files

libr/socket/meson.build:30: DEPRECATION: Library r_socket was passed to
the "libraries" keyword argument of a previous call to generate() method
instead of first positional argument. Adding r_socket to "Requires" field,
but this is a deprecated behaviour that will change in a future version
of Meson. Please report the issue if this warning cannot be avoided in
your case.
2018-12-27 14:17:54 +01:00
David CARLIER
033e073c4e Little warning build fixes (#12232) 2018-11-20 01:13:54 +01:00
radare
5f270658c5
New RBin plugin for "symbols" files ##bin 2018-11-19 22:54:58 +01:00
dav1901
8b83d03c99 Minor code cleanups free/R_FREE (#12145) 2018-11-13 23:41:28 +01:00
dav1901
9b0fbf1ee4 Minor code cleanups - free/R_FREE/etc 2018-11-13 00:23:49 +01:00
lzutao
b790439e28 Cast arguments to ut8 when feeding ctype.h functions ##refactor
The behavior of the `<ctype.h>` functions is undefined for negative
arguments (other than `EOF`). In such a situation, the argument should
be cast to `unsiged char` for safety.

References:
 - C Programming: A Modern Approach, 2nd Edition: page 612, chapter 23.5
2018-11-06 13:40:00 +01:00
pancake
865ec593b1 Dont make those reg profile dupes fatal 2018-11-05 16:55:34 +01:00
pancake
3738a97623 Fix several asserts and crashes when loading invalid reg profiles 2018-11-05 16:55:34 +01:00
radare
88e49ac207
Fix #11972 - fix null entry assert on mach0 libs ##bin (#11990) 2018-10-30 01:07:24 +01:00
pancake
4618c4620c Fix some more license headers 2018-10-29 23:30:02 +01:00
pancake
dc96db9e51 Try clang-format when no uncrustify is found and reindent r_reg with sys/indent.sh 2018-10-16 00:17:44 +02:00
pancake
ec875e8e15 Delete dead code 2018-10-16 00:17:44 +02:00
pancake
4205cdabee Fix memory leaks in RReg 2018-10-16 00:17:44 +02:00
Neven Sajko
4a722e80d8 Add braces to if, else, for, while ... (#11504) 2018-09-13 10:17:26 +02:00
Riccardo Schirone
eee1385466
Meson private (#11331)
* meson: refactor library cflags
* meson: use visibility=hidden by default
* remove unused var
* magic/meson: replace tabs with spaces
2018-09-03 10:07:28 +02:00
radare
63669bee85
Add support for wired-to-ground registers for MIPS and V850 (#11320) 2018-08-31 03:05:41 +02:00
sivaramaaa
8a2397e4b1 Improve syscall search (#11058) 2018-08-13 03:13:25 +02:00
Riccardo Schirone
7572f315ea
meson improvements (#10617)
* meson.build: fix meson build when not on git
* meson.build: make capstone a dependency
* meson.build: make r_magic library optional
* meson.build: capstone include is already in the dependency
* meson.build: use dependencies instead of manual linking + includes
* meson.build: add travis
* flag/meson.build: include sdb dependency
* travis-script: print messages based on install system
* io/meson.build: add sdb as dependency
* syscall/meson.build: missing sdb dependency
* {parse,config}/meson.build: add sdb dependency
* travis.yml: pass INSTALL_SYSTEM var to docker
* {bin/shlr}/meson.build: add sdb_dep to r2java and bin
* install meson and ninja-build in r2-travis docker
* travis.yml: allow meson build to fail for now
* anal/meson.build: add sdb and java dependencies
* egg/meson.build: add sdb dependency
* travis.yml: meson build env should be also in the includes list
* core/meson.build: add java dep
* meson.build: use dependencies also to create main r2 dependency
* rasm2/meson.build: replace link_with with dependencies
* rasm2/meson.build: add sdb as dependency
* meson.builds: convert link_with to dependencies and fix tabs
* travis-script: change meson install prefix and set PKG_CONFIG_PATH
* travis-script: add lib64 to LD_LIBRARY_PATH
2018-07-09 16:58:38 +02:00
Alex Gaines
78ece9fd2b very minor optimization here, but it improved the performance of r_reg_32_to_64 quite significantly... Profiling a test program that used libr_anal esil went from r_reg_32_to_64 using ~9.5% to ~2.3% of the total time (#10624) 2018-07-05 00:24:06 +02:00
pancake
91a2e5fb9d More killing of strcasecmp/strncasecmp 2018-05-21 22:13:07 +02:00
Paul I
cc90ec6be5 [WIP] Move hardcoded paths to r_userconf.h (#9959)
* Move hardcoded paths to r_userconf.h

* Add R2_HOME_* macros

* Some cleanup
2018-04-28 10:02:55 +02:00
Paul I
40b4a5b557 Meson: disable libversion info for Windows (#9858) 2018-04-10 22:44:54 +02:00
Paul I
ca3652da4b Meson: Add version info for shared libs (#9763) 2018-03-24 18:18:32 +01:00
Paul I
4e73ad7d19 Meson: some cleanup (#9753) 2018-03-23 07:47:46 +01:00
Florian Märkl
5e1f811ec0 Fix meson indentation (#9567) 2018-03-03 22:08:37 +01:00
Florian Märkl
95a1b75784 Install Headers and .pc Files with Meson (#9548)
Use meson pkgconfig for .pc files

meson 0.44

Install same headers as acr
2018-03-03 20:00:18 +08:00
Paul I
bb4f61580e Cleanup meson files (#9424) 2018-02-20 09:33:19 +01:00
pancake
6b053ccf59 Fix hexagon register profile 2018-02-02 23:03:14 +01:00
Fangrui Song
94ba8ea79a reg/profile.c: remove a duplicated FLG => GPR hack (#8516) 2017-09-15 11:32:29 +02:00
Fangrui Song
cab86b882d Fix ar <type>, I suggest using -1 for any, 0 for anal->bits, >0 for exact bits (#8435) 2017-09-12 01:53:52 +02:00
pancake
2b181659f0 Fix regprofile parsing from remote lldb on ios-arm64 2017-08-30 01:17:39 +02:00
Fangrui Song
c66aaa84f7 Add r_reg_{get,set}_value_by_role and fix "aef" because "PC" is not available on every arch (#8326) 2017-08-27 01:10:19 +02:00
pancake
d9cf73469d Add support for 27bit middle-endian registers in r_reg 2017-07-27 22:57:18 +02:00
Guillaume Valadon
a8ad435c10 Typos fixed (#7970) 2017-07-20 10:44:43 +02:00
pancake
1a04c2a24d Get ready for the 1.6 release 2017-07-10 01:32:50 +02:00
Srimanta Barua
4fdb21643c added drp sub-command to parse gdb reg profile and dump r2 one (#7889) 2017-07-09 18:18:27 +02:00
SkUaTeR
c31d81da26 support for static build (#7822)
* support for static build
* improved sharard/static build
2017-06-28 22:54:40 +02:00
SkUaTeR
dc7914644e Meson improvements 2017-05-31 13:38:47 +02:00
pancake
20f7ac66cc Bring back drx on XNU, buggy but at least does something 2017-05-27 03:57:30 +02:00
SkUaTeR
9a1337512a meson.build fixes to build with MSVC 2017-05-14 23:06:00 +02:00
SkUaTeR
beb80cfc16 Fixes for MSVC 2017-05-09 23:53:20 +02:00
pancake
60f9667654 Remove support for bjam build system
- Delete all Jamroot files
2017-05-02 05:48:40 +02:00
pancake
fa671b9a16 Initial support for the Meson build system
- Integrated with current ACR
- Fix some stale fails got removed
2017-05-02 05:05:36 +02:00
alvarofe
9686de1404 Refactor r_reg_arena_push to remove dead code 2017-04-18 00:59:49 +02:00
pancake
a66cc10d46 Fix a huge list of null derefs from clang-analyzer 2017-04-17 22:02:04 +02:00
Ren Kimura
ce5758b739 Add reverse singlestep command 'dsb' (#7116) 2017-03-25 16:00:25 +01:00
davidpolverari
1fb422b532 Fix #6162 - Renames r_str_concat to r_str_append 2017-03-16 22:29:49 +01:00
Giovanni
43532031c4 Fixes for windows and some are also global (#6936) 2017-03-08 08:49:31 +01:00
pancake
93eb47ccac Update SDB fixing stack exhaustion in merge sort and enhance indentation scripts 2017-02-12 22:44:13 +01:00
pancake
70930f4496 Bring back the interest on sys/indent.sh 2017-02-10 02:05:58 +01:00
Elia Geretto
31e8d7cb68 Fix various memory leaks (#6272)
* Fix bits_ranges memory leak in anal.c
* Fix anal->reg memory leak and prevent use after free in plugin.c
* Fix reg->allregs memory leak in reg.c
* Fix dbg->plugins memory leak in debug.c
* Fix io->plugin_default memory leak in io.c
* Fix plugin_free not deallocating plugin in bin.c
* Adapt to style guidelines
* Fix memory leak in r_bin_object_free and resolve double free
* Fix o->kv memory leak in r_bin_object_set_items
* Fix memory leak pushing arena on reg init
* Fix io->plugin_default memory leak in io.c
* Adapt to style guidelines
* Fix pfile memory leak in radare2.c
* Add braces to if in bin.c
2016-12-01 09:09:59 +01:00
pancake
546332dd03 ha ha ha, shrink grows! 2016-11-14 16:08:05 +01:00
pancake
7a68fd2d82 Attempt to fix the register profile reloading issue 2016-11-14 15:59:50 +01:00
pancake
6abe6abe93 Shrink all arenas before reloading the new reg profile 2016-11-24 00:29:34 +01:00
SkUaTeR
4c2a01d4a7 Fix in profile to get correct reg.size (#6238) 2016-11-21 23:13:59 +01:00
pancake
d32e97ace8 Fix #6228 - Double 0x in dr= 2016-11-20 11:30:15 +01:00
Álvaro Felipe Melchor
645b273bb9 loosen up constraint in value.c 2016-11-16 20:49:20 +01:00
pancake
a7e281b524 Enhanced drpi and use gpr as default arena for flags 2016-11-15 16:20:10 +01:00
pancake
7fb8c24be3 Add drpi to show internal representation of drp and check for overflows 2016-11-15 14:40:16 +01:00
Álvaro Felipe Melchor
4915466256 Fix oob due to reg arena changes 2016-11-15 01:12:37 +01:00
SkUaTeR
20a9bbd14a Rreg fpu changes (#6191)
* test with rreg for values greater than 64
* check for redirected regs in debug reg sync
2016-11-14 23:58:29 +01:00
pancake
24e08bb23d Aim to fix the asm.emu regression after the memoization 2016-11-13 23:32:24 +01:00
pancake
77f1b4fbf5 Add @arena modifier to the 1st column in the reg profile 2016-11-12 23:19:03 +01:00
pancake
94d47c79bb Completely remove all references to list.h 2016-10-27 13:33:27 +02:00
Francesco Tamagni
f41f74c527 Fix #4497 - Recursive function emulation 2016-10-24 14:31:03 +02:00
pancake
05220c2fe0 Fix overflow in debug.reg_read 2016-10-09 23:52:24 +02:00
Sven Steinbauer
2996538700 Fix #5633 - Change x == NULL to correct syntax 2016-09-19 14:44:47 +02:00
pancake
3654e5f33b Fix regression in reg.type=flg 2016-08-14 19:12:52 +02:00
pancake
f60597b2ee Fix ar 1 to honor RReg.Type.flg 2016-08-14 02:23:47 +02:00
pancake
2f339144f4 Fix some latest covs 2016-08-05 13:25:20 +02:00
Maijin
7938640445 Move all /t/ from r2 to r2r 2016-07-27 19:19:30 +02:00
Maijin
c274afe748 Fix #3286 - Use stdbool.h 2016-07-12 22:15:19 +02:00
Jeffrey Crowell
7436b51095 add r_reg_32_to_64 for @condret
closes #5206
2016-06-25 00:03:44 -04:00
pancake
d3394d5a7a Fix latest 28 COVs 2016-06-02 03:19:31 +02:00
pancake
2138ca700c Fix #5019 - registers are now accessible by index 2016-05-31 14:11:09 +02:00
Sven Steinbauer
547f8bbc5c Infer fixes Round 2 (#4993) 2016-05-24 22:22:15 +02:00
pancake
c36b299073 Fix some null deref and rarun2 chroot escape vuln 2016-05-24 12:32:45 +02:00
Sushant Dinesh
cf456f4414 Fixes to ESIL (#4951)
- Reverted ADD and ADC to set flags based on internal variables
- Fixed calculation of carry and zero flags from internal vars
- Revert "ESIL: add floating point instructions (#4794)"
  This reverts commit 964d12b392. Since we
  decided that floating point operations will be implemented using separate
  ops, these unions are no longer needed. This commit introduced a regression
  in setting esil->old and esil->cur
- Style fixes
2016-05-23 16:39:54 +02:00
Damien Zammit
af0a865d9f WIP - Totally remove host endianness dependence
- Adds endian aware functions
- Removes references to host endian
- Uses binary detected endianness else tries LE and restricts by RAsmPlugin
- Fixes gdb debugger endianness when debugging BE qemu gdbserver

Signed-off-by: Damien Zammit <damien@zamaudio.com>
2016-05-04 23:42:17 +10:00
pancake
1f82c105fb Fix doublefree and regprofile for FreeBSD 2016-05-04 13:28:53 +02:00
NaveenBoggarapu
4c04b98b47 few memory leaks fixed 2016-04-13 21:55:48 +02:00
pancake
4476720aa8 Fix regprofile regression 2016-04-08 13:36:15 +02:00
Lukas Dresel
5a4fe03d41 Fix #4495 - rasm2 not loading all the plugins
- Fixed misplaced free(tmp) i broke
- Made plugin loading work the same in every tool.
- Removed last instances of hardcode 'LIBR_PLUGINS' string
2016-04-05 22:42:19 +02:00
pancake
740e43eadd Fix some segfault and consistencies 2016-04-04 01:59:30 +02:00
Mizari
477986be2c Removed possible null dereference and one clang-analyzer warning squashed 2016-04-01 10:34:28 +02:00
Mizari
d6daa9d591 Fixed function calls for r_reg_set_bytes(reg,-1...) 2016-03-24 12:47:00 +01:00
Mizari
59d614edf1 Added drw/arw command + r_reg_arena_set_bytes 2016-03-22 11:48:42 +01:00
pancake
805e3f26e8 Fixes for lldb/debugserver on x86-64 2016-02-03 12:09:58 +01:00
pancake
6c931a091f Automatic asm.bits depending on CPSR's Thumb bit 2016-01-11 03:08:24 +01:00
pancake
9bd4e213b2 Enhance cpsr in ARM and handle new bitsize syntax in reg profile 2016-01-11 02:35:57 +01:00
pancake
7bef915a8d Implement arC/drC to show comments in regprofiles 2016-01-09 03:14:18 +01:00
pancake
4e6be05f62 ARM's SP is r13 and add LR in r14 2015-12-31 14:10:11 +01:00
pancake
cfb03d3772 More indentation fixes 2015-12-09 00:27:31 +01:00