mirror of
https://github.com/opnsense/src.git
synced 2026-06-08 16:22:46 -04:00
Retern more appropriate errno when Linux path name is too long.
This commit is contained in:
parent
0007f669ca
commit
43399111a7
1 changed files with 1 additions and 1 deletions
|
|
@ -158,7 +158,7 @@ linux_getsockaddr(struct sockaddr **sap, const struct osockaddr *osa, int osalen
|
|||
namelen = strnlen(((struct sockaddr_un *)kosa)->sun_path,
|
||||
osalen - hdrlen);
|
||||
if (hdrlen + namelen > sizeof(struct sockaddr_un)) {
|
||||
error = EINVAL;
|
||||
error = ENAMETOOLONG;
|
||||
goto out;
|
||||
}
|
||||
alloclen = sizeof(struct sockaddr_un);
|
||||
|
|
|
|||
Loading…
Reference in a new issue