topical media & game development
basic-shell-extra-10-return.sh / sh
Ã#!/bin/sh
implicit_good_return ()
{
echo
}
explicit_good_return ()
{
echo
return
this wont ever be executed
}
implicit_bad_return ()
{
nosuchcommand
}
explicit_bad_return ()
{
nosuchcommand
return 127
}
implicit_good_return
echo "Return value from implicit_good_return function: ?"
implicit_bad_return
echo "Return value from implicit_bad_return_function: ?"
(C) Æliens
20/2/2008
You may not copy or print any of this material without explicit permission of the author or the publisher.
In case of other copyright issues, contact the author.