Elevate .text.syscall to .privileged
It turns out adding OpenBSD msyscall() origin verification broke the --ftrace flag. The executable needs to issue raw syscalls while it's rewriting itself. So they need to be in the same section, and that's just plain simpler too.
This commit is contained in:
@@ -48,7 +48,7 @@ static void __sys_print_nt(const void *data, size_t len) {
|
||||
* @param len can be computed w/ tinystrlen()
|
||||
* @clob nothing except flags
|
||||
*/
|
||||
textsyscall void __print(const void *data, size_t len) {
|
||||
privileged noinline void __print(const void *data, size_t len) {
|
||||
int64_t ax, ordinal;
|
||||
if (WasImported(__imp_WriteFile)) {
|
||||
__sys_print_nt(data, len);
|
||||
|
||||
Reference in New Issue
Block a user