[llvm-commits] [llvm] r116671 - /llvm/trunk/tools/llvm-stub/llvm-stub.c

Benjamin Kramer benny.kra at googlemail.com
Sat Oct 16 08:43:02 PDT 2010


Author: d0k
Date: Sat Oct 16 10:43:02 2010
New Revision: 116671

URL: http://llvm.org/viewvc/llvm-project?rev=116671&view=rev
Log:
Hack around incompatible pointer warnings.

Modified:
    llvm/trunk/tools/llvm-stub/llvm-stub.c

Modified: llvm/trunk/tools/llvm-stub/llvm-stub.c
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-stub/llvm-stub.c?rev=116671&r1=116670&r2=116671&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-stub/llvm-stub.c (original)
+++ llvm/trunk/tools/llvm-stub/llvm-stub.c Sat Oct 16 10:43:02 2010
@@ -64,7 +64,11 @@
   memcpy((char **)Args+2, argv+1, sizeof(char*)*argc);
 
   /* Run the JIT. */
-  execvp(Interp, Args);
+#ifndef _WIN32
+  execvp(Interp, (char **)Args); /* POSIX execvp takes a char *const[]. */
+#else
+  execvp(Interp, Args); /* windows execvp takes a const char *const *. */
+#endif
   /* if _execv returns, the JIT could not be started. */
   fprintf(stderr, "Could not execute the LLVM JIT.  Either add 'lli' to your"
           " path, or set the\ninterpreter you want to use in the LLVMINTERP "





More information about the llvm-commits mailing list