Set errno to EFTYPE instead of EINVAL to be more consistent with the
rest of code. MFC after: 1 month
This commit is contained in:
parent
bac78aa2a4
commit
7ef84b00ca
@ -281,7 +281,7 @@ zread(void *cookie, char *rbp, int num)
|
|||||||
if (zs->u.r.zs_code > zs->zs_free_ent ||
|
if (zs->u.r.zs_code > zs->zs_free_ent ||
|
||||||
zs->u.r.zs_oldcode == -1) {
|
zs->u.r.zs_oldcode == -1) {
|
||||||
/* Bad stream. */
|
/* Bad stream. */
|
||||||
errno = EINVAL;
|
errno = EFTYPE;
|
||||||
return (-1);
|
return (-1);
|
||||||
}
|
}
|
||||||
*zs->u.r.zs_stackp++ = zs->u.r.zs_finchar;
|
*zs->u.r.zs_stackp++ = zs->u.r.zs_finchar;
|
||||||
|
Loading…
Reference in New Issue
Block a user