Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: trapped in bash



On Dec 18,  8:29pm, Ray Andrews wrote:
}
} Not for me to say, but it seems to me that the simple fact that a file 
} exists or does not exist is simple enough to determine

Well, yes.

The shell finds the file, because it's responsible for path search.

It then forks, and the child process passes the full path to execve(),
which replaces the child shell with the kernel code that is supposed
to start up the new executable.

That kernel code then fails for whatever reason -- in this case, it's
because the 32-bit library is not found -- and returns a nonzero
numeric exit code to the parent shell.

The parent shell prints the message associated with that error code.
It isn't responsible for guessing what caused the error; there could
for example have been additional rounds of finding and exec'ing other
paths of which the parent has no knowledge, before a final exit.



Messages sorted by: Reverse Date, Date, Thread, Author