You've already forked ReZygisk
mirror of
https://github.com/PerformanC/ReZygisk.git
synced 2025-09-06 06:37:01 +00:00
improve: companion.c, dl.c and utils.c code
This commit improves the code for multiple files by making "read_string" function already make the string NULL-terminated, avoiding code duplication. Also for "companion.c" fixes an "if" where it would read "client_fd" and check if "fd" is equal to "-1", instead of "client_fd", also does some overall code improvements there like detaching the thread, avoiding memory leaks in the exit, of the thread itself.
This commit is contained in:
@@ -91,7 +91,7 @@ read_func_def(uint8_t);
|
||||
|
||||
ssize_t write_string(int fd, const char *restrict str);
|
||||
|
||||
ssize_t read_string(int fd, char *restrict str, size_t len);
|
||||
ssize_t read_string(int fd, char *restrict buf, size_t buf_size);
|
||||
|
||||
bool exec_command(char *restrict buf, size_t len, const char *restrict file, char *const argv[]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user