inject error set errno to ENOTTY rather than 0; minor log message fix