From 33397a399c608830614d8061fe13db7ebabd0bf7 Mon Sep 17 00:00:00 2001 From: Jo-Philipp Wich Date: Tue, 15 Mar 2022 00:22:48 +0100 Subject: uloop: use execvp() on OS X Since `execvpe()` is a GNU extension, fall back to using `execve()` on OS X. Signed-off-by: Jo-Philipp Wich --- lib/uloop.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'lib/uloop.c') diff --git a/lib/uloop.c b/lib/uloop.c index bc57336..b74633d 100644 --- a/lib/uloop.c +++ b/lib/uloop.c @@ -534,8 +534,13 @@ uc_uloop_process(uc_vm_t *vm, size_t nargs) free(buf); } +#ifdef __APPLE__ + execve((const char *)ucv_string_get(executable), + (char * const *)argp, (char * const *)envp); +#else execvpe((const char *)ucv_string_get(executable), (char * const *)argp, (char * const *)envp); +#endif _exit(-1); } -- cgit v1.2.3