mirror of
https://git.FreeBSD.org/src.git
synced 2025-01-17 15:27:36 +00:00
In at_setsockaddr(), assert that ddp != NULL, rather than returning an
error if it's NULL, as so_pcb != NULL is now an invariant.
This commit is contained in:
parent
441201ce65
commit
3c09bd01d8
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=157130
@ -255,9 +255,8 @@ at_setsockaddr(struct socket *so, struct sockaddr **nam)
|
||||
struct ddpcb *ddp;
|
||||
|
||||
ddp = sotoddpcb(so);
|
||||
if (ddp == NULL) {
|
||||
return (EINVAL);
|
||||
}
|
||||
KASSERT(ddp != NULL, ("at_setsockaddr: ddp == NULL"));
|
||||
|
||||
DDP_LOCK(ddp);
|
||||
at_sockaddr(ddp, nam);
|
||||
DDP_UNLOCK(ddp);
|
||||
|
Loading…
Reference in New Issue
Block a user