diff options
author | rwatson <rwatson@FreeBSD.org> | 2007-05-27 17:02:54 +0000 |
---|---|---|
committer | rwatson <rwatson@FreeBSD.org> | 2007-05-27 17:02:54 +0000 |
commit | 933cc5abb3fc5e0afc41fd1420765773cc08e548 (patch) | |
tree | 786e5a2aba0a863f8dde3ca1828eb4a3f9f116d3 | |
parent | 135548ec9b4ad638980577472e2db337f3e6c5b1 (diff) | |
download | FreeBSD-src-933cc5abb3fc5e0afc41fd1420765773cc08e548.zip FreeBSD-src-933cc5abb3fc5e0afc41fd1420765773cc08e548.tar.gz |
Don't assign sp to the value of s when we're about to assign it instead to
s + strlen(s).
Found with: Coverity Prevent(tm)
CID: 2243
-rw-r--r-- | sys/netinet/tcp_subr.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/netinet/tcp_subr.c b/sys/netinet/tcp_subr.c index 500a00d..2f300d5 100644 --- a/sys/netinet/tcp_subr.c +++ b/sys/netinet/tcp_subr.c @@ -2101,7 +2101,7 @@ tcp_log_addrs(struct in_conninfo *inc, struct tcphdr *th, void *ip4hdr, 2 * INET_ADDRSTRLEN; #endif /* INET6 */ - s = sp = malloc(size, M_TCPLOG, (M_ZERO|M_NOWAIT)); + s = malloc(size, M_TCPLOG, M_ZERO|M_NOWAIT); if (s == NULL) return (NULL); |