2 Extern implementation of Nit module exec
7 #include "core__exec._ffi.h"
9 #include <android/log.h>
10 #define PRINT_ERROR(...) (void)__android_log_print(ANDROID_LOG_WARN, "Nit", __VA_ARGS__)
12 #define PRINT_ERROR(...) fprintf(stderr, __VA_ARGS__)
14 #line 19 "../lib/core/exec.nit"
23 #include <sys/types.h>
32 typedef struct se_exec_data se_exec_data_t
;
45 long core__exec___CString_system___impl( char* self
)
47 #line 457 "../lib/core/exec.nit"
50 int status
= system(self
);
52 if (WIFSIGNALED(status
) && WTERMSIG(status
) == SIGINT
) {
53 // system exited on SIGINT: in my opinion the user wants the main to be discontinued
54 kill(getpid(), SIGINT
);