Add error checks to @shell
Check errors from Lua io.* library calls to make it show useful error messages
when they do occur instead of ("attempt to index a nil value")
Submitted by: RhToad (in IRC) <andrew@tao173.riddles.org.uk>
Differential Revision: https://reviews.freebsd.org/D27154