Commit Graph

236 Commits

Author SHA1 Message Date
pancake aa7de006e6 Fix TinyCC build ##build 2020-09-27 13:33:26 +08:00
Kārlis Seņko 7042ae727b Refactor r_str_split_lines to use size_t. 2020-09-21 07:48:17 +03:00
Khairul Azhar Kasmiran d9057505dc
Set RPATH/RUNPATH on r2 libs too if local (#17639) 2020-09-15 09:16:14 +02:00
Riccardo Schirone 594b940b7c
Fixes some of the issues in Travis (#17267)
* Do not check with r_return_ if the convention is present

Let's just assume the NULL default in such a case, so that architectures
for which we don't have a defined calling convention can still be
processed somehow by the analysis code. It won't be precise, but it's
better than nothing.

Also add a warning message so users are aware when the calling
convention is not defined.

* Fix oob-read when # is at the end of the cmd string

* Do not set TMPDIR when the new value is the empty string

When TMPDIR is set to empty value, clang+ld behaves in weird ways and
you cannot compile files from within the r2 shell (e.g. when using #!c
or #!cpipe)

* Use meson and add -lasan to pkgconfig files when sanitizer are used
2020-07-16 20:47:30 +08:00
pancake bd9a604a87
Check for return values in about ~50 method calls (#17025) 2020-06-15 11:24:43 +02:00
pancake 160fc95e66
Use (void) instead of () in function signatures (#17026) ##refactoring
* Use (void) instead of () in function signatures
* Add test to avoid further contributions to commit the same mistake
2020-06-14 16:08:32 +02:00
Anton Kochkov ffe743ef39
Fix #4056 - rename DEPS to R2DEPS ##build (#17020)
* Rename DEPS to R2DEPS
* Cleanup of sys/build.sh
2020-06-12 10:49:28 +08:00
Liumeo 3b7f014040
pointer type mismatch warning (#16695) 2020-04-23 08:59:46 +02:00
Liumeo dbc9d5e462
Fix 2 LGTM alerts (#16626) 2020-04-18 20:35:20 +02:00
Liumeo 2570a7b001
Add header guard (#16605) 2020-04-16 18:41:31 +02:00
radare 3f77b9a76b
Avoid duplicated module filenames to fix static.sh ##build (#16403) 2020-04-02 14:30:27 +02:00
Paul I 0e62dda341
Fix fgets() usage (#16068) 2020-02-29 20:47:10 +01:00
radare 1ac6209c88
Fix #14424 - Handle ~ operator in the `ms` shell ##cons (#15846) 2020-01-19 07:40:21 +01:00
pancake db3ab7e3f9 Fix cannot mount fs harmless warning message ##mount 2019-08-04 09:29:36 -07:00
pancake 9f4f802cec Fix build --without-gpl 2019-07-10 19:45:34 +02:00
radare dc0892a1a0
Towards emscripten build fix (update sdb) ##build 2019-07-07 16:52:41 +02:00
Francesco Tamagni d4a48a50d8 Improve R_FS via IO ##fs
- add `r_fs_file_copy_abs_path` to get the absolute path of a RFSFile, centralizing edge case handling
- use that in `fs_io_read`
- add missing `free (file->path)` in RFSFile destructor
- fix `handlePipes` for fs shell `cat` use case
2019-06-28 02:36:25 +02:00
Anton Kochkov 20e19d6023 More spelling fixes in the code 2019-06-20 13:36:02 +08:00
radare a49bb7cf66
Change the signature of r_str_trim to avoid confusions ##refactor 2019-06-16 20:58:40 +02:00
radare 571a080ca7
s/CORELIB/R2_PLUGIN_INCORE/g (#14295) 2019-06-13 19:12:51 +02:00
pancake 90fd81ca81 Fix warnings here and there 2019-05-14 10:44:19 +02:00
pancake 305ddc46a9 Implement mw command and fix segfault on old fs support ##bin 2019-05-10 11:25:35 +02:00
pancake d8b283f8c6 Improve the RFS API to support write and unlink operations ##fs
* In fs_r2: /seek and /bsize and fix flags and config writes
* fs.shell supports echo and redirections '>'
2019-05-10 11:25:35 +02:00
Anton Kochkov bb67b54f74
Remove CYGWIN & MINGW remnants (#13377) 2019-03-15 12:55:08 +08: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
Paul I b2c7f7ef6c Some fixes (#12670) 2019-01-07 00:29:23 +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
Riccardo Schirone 738bc9cb19 Fix warnings by using more r_str_ncpy
* Fix wrong logic in visual_search

When the string to be searched is wrapped in " ", you want to remove the
first and last quotes and look only for the internal string.

* Increase size to prevent string truncation (and fix compiler warning)
* Fix "destination unchanged after copying no bytes" warning
* Move msp430_register_names where it belongs to
* Fix Wstringop-truncation warning
2018-12-19 12:07:49 +01:00
dav1901 c7e6735105 Prevent double freeing (#12319) 2018-11-25 14:37:37 +01:00
dav1901 a6b44e03fe Fix warnings (#12309) 2018-11-25 01:46:57 +01:00
BlaCoiso 2af904856f Fix mount shell and ed commands (#12312) 2018-11-24 22:52:08 +01:00
radare d05292e485
Fix 80 warnings coming from gcc8.2 (#12280) 2018-11-22 22:11:43 +01:00
pancake 8caa2ba2ee Fix sys/sdk.sh (--without-gpl) 2018-09-26 10:03:32 -07:00
Paul I bf29250ddd Fix #11487 (#11534) 2018-09-15 22:52:12 +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
Fangrui Song beda5da178 meson: disable inclusion-only .c files (#10982) 2018-08-08 09:04:07 +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
Paul I 7e9f982849 Meson: some cleanup (#10076) 2018-05-16 10:24:35 +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
davidpolverari f87d43899f WIP: Handle path tab autocompletion in RFShell (#9837) 2018-04-24 13:57:17 +02:00
Paul I 40b4a5b557 Meson: disable libversion info for Windows (#9858) 2018-04-10 22:44:54 +02:00
pancake 2a8ab337d9 WIP: Initial implementation of RFShell tab autocompletion 2018-04-09 01:15:20 +02:00
Paul I ca3652da4b Meson: Add version info for shared libs (#9763) 2018-03-24 18:18:32 +01:00
pancake 092695d262 Fix last covs mainly in r_fs 2018-03-23 12:52:56 +01:00
Paul I 4e73ad7d19 Meson: some cleanup (#9753) 2018-03-23 07:47:46 +01:00
pancake eb3370f47d Make RFShell initialization more flexible 2018-03-21 12:02:22 +01:00
davidpolverari b29998f3f2 Implement dietline history on mount-shell (#8806). (#9534)
* Implement dietline history on mount-shell (#8806).

Gives minimal dietline history support inside mount-shell. There is
still a need to implement autocompletion.
2018-03-21 11:59:39 +01:00
Lowly Worm 12d291be0f fix double free in r_fs_find_off_aux 2018-03-04 11:10:19 -08:00
Florian Märkl 5e1f811ec0 Fix meson indentation (#9567) 2018-03-03 22:08:37 +01:00