[Mono-dev] execv fails with error status 126

Paolo Molaro lupus at ximian.com
Thu Oct 18 12:48:55 EDT 2007


On 10/18/07 C S Vadiraj wrote:
> Here you go. Sorry for having missed it in my previous reply.
> 
> [DllImport ("libc")]
>         private static extern int execv (string cmd, string[] args);
> 
> execv ("/tmp/myscript", (string[]) list.ToArray (typeof (string)));
> list is Array list with set of arguments. Not NULL terminated.

And there is your error in your code. That answers also the question
you made in your last email:) Read the man page, the array must be
null-terminated.

> I have further error messages on this application which failed with mono 1.2.0 version too.
> Please fine it below.

If you bind incorrectly to a dllimport method anything can happen.
Fix the bug in your code and then report back if you have any issue in
mono.
Thanks.

lupus

-- 
-----------------------------------------------------------------
lupus at debian.org                                     debian/rules
lupus at ximian.com                             Monkeys do it better



More information about the Mono-devel-list mailing list