Set errno to EFTYPE instead of EINVAL to be more consistent with the rest of code.
MFC after: 1 month