Page MenuHomeFreeBSD

D57104.diff
No OneTemporary

D57104.diff

diff --git a/sys/netinet/tcp_syncache.c b/sys/netinet/tcp_syncache.c
--- a/sys/netinet/tcp_syncache.c
+++ b/sys/netinet/tcp_syncache.c
@@ -1559,6 +1559,7 @@
if (sc->sc_ipopts)
(void)m_free(sc->sc_ipopts);
sc->sc_ipopts = ipopts;
+ ipopts = NULL;
}
/*
* Update timestamp if present.
@@ -1673,6 +1674,7 @@
sc->sc_cred = NULL;
sc->sc_port = port;
sc->sc_ipopts = ipopts;
+ ipopts = NULL;
bcopy(inc, &sc->sc_inc, sizeof(struct in_conninfo));
sc->sc_ip_tos = ip_tos;
sc->sc_ip_ttl = ip_ttl;
@@ -1819,13 +1821,14 @@
tfo_expanded:
if (cred != NULL)
crfree(cred);
- if (sc == NULL || sc == &scs) {
#ifdef MAC
+ if (sc == NULL || sc == &scs)
mac_syncache_destroy(&maclabel);
#endif
- if (ipopts)
- (void)m_free(ipopts);
- }
+ if (sc == &scs)
+ ipopts = sc->sc_ipopts;
+ if (ipopts != NULL)
+ (void)m_free(ipopts);
return (rv);
}

File Metadata

Mime Type
text/plain
Expires
Mon, Aug 17, 12:58 AM (37 m, 52 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
33682508
Default Alt Text
D57104.diff (880 B)

Event Timeline