blob: 10e133fb6139079c5bb49b3e4f73d76ab383f979 [file]
#include <errno.h>
#include <stdio.h>
#include <unistd.h>
int main(int argc, char *argv[]) {
printf("calling exec...\n");
fflush(NULL);
// Kotlin executable name is in argv[1]
// Forward argv[2..n] to kotlin executable as arguments (the first one should be the programName according to posix)
execv(argv[1], &(argv[2]));
perror("execv failed");
return 1;
}