sh: Parse a larger number of error messages
In order to trigger a non-EIO failure, a script had to output
_exactly_ 'EINVAL ' or similar, with one trailing space and no other
message, because we forgot to limit the length of the string
comparison. Fix things to tolerate an error name without a message, as
well as to be case-insensitive.
Also, parse EOVERFLOW (missed in commit
6f8c8084).
The next patch will add a test to avoid regressions.
Not done here but perhaps worth considering: if the first portion of
the scripts output resembles a numeric value, we could see if that
matches a known errno value.
Fixes:
262787dc86
Signed-off-by: Eric Blake <eblake@redhat.com>