execl -- fails with ENOEXEC (Exec Format error)

Rudrakshala Purushotham rudrak at saphir.cl.bull.fr
Tue Oct 23 22:15:00 AEST 1990


I have a problem with the following code:

	...
	execl ("/usr/local/bin/Rnmail", "Rnmail", "name at something", (char *)0);
	perror ("execl");
	...

	results in:

	execl: Exec format error

	where as

	...
	execl ("/bin/sh", "-c", "Rnmail", "name at something", (char *)0);
	perror ("sh");
	...

	works fine.

Can somebody explain me this behaviour?  I am using UNIX System V Rel 3.0
--
R. Purushotham							Email: rudrak at saphir.cl.bull.fr
F7 1 D5, BULL SA,                       Tel Off: 34627000 ext 3928
78340 Les Clayes sous Bois  FRANCE    	Tel Res: 34604752
=======================================================================



More information about the Comp.unix.programmer mailing list