cvs commit: src/sys/netinet ip_divert.c raw_ip.c udp_usrreq.c src/sys/netinet6 raw_ip6.c udp6_usrreq.c

Pawel Jakub Dawidek pjd at FreeBSD.org
Sun Apr 9 08:57:21 UTC 2006


On Sat, Apr 01, 2006 at 04:20:54PM +0000, Robert Watson wrote:
+> rwatson     2006-04-01 16:20:54 UTC
+> 
+>   FreeBSD src repository
+> 
+>   Modified files:
+>     sys/netinet          ip_divert.c raw_ip.c udp_usrreq.c 
+>     sys/netinet6         raw_ip6.c udp6_usrreq.c 
+>   Log:
+>   Update in_pcb-derived basic socket types following changes to
+>   pru_abort(), pru_detach(), and in_pcbdetach():
[...]
+> -	if (inp == 0) {
+> -		INP_INFO_WUNLOCK(&divcbinfo);
+> -		return EINVAL;
+> -	}
+> +	KASSERT(inp == NULL, ("div_bind: inp == NULL"));

This change seems to be wrong. EINVAL was returned when inp is equal to
NULL and now you assert it. I think panic message is correct, but the
check isn't. I haven't triggered the assert, though.

+> -	if (inp != 0) {
+> -		INP_INFO_WUNLOCK(&udbinfo);
+> -		return EINVAL;
+> -	}
+> -
+> +	KASSERT(inp == NULL, ("udp6_attach: inp == NULL"));

Incorrect panic message here? Should be "udp6_attach: inp != NULL".

-- 
Pawel Jakub Dawidek                       http://www.wheel.pl
pjd at FreeBSD.org                           http://www.FreeBSD.org
FreeBSD committer                         Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/cvs-src/attachments/20060409/7f5ee5cb/attachment.pgp


More information about the cvs-src mailing list