diff options
author | Lennart Poettering <lennart@poettering.net> | 2020-09-08 19:41:44 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2020-09-08 19:47:30 +0200 |
commit | 0354029bf572489bf968a39c537ec0cbdef828ce (patch) | |
tree | 9b1620bf488e5c534cb673d8ab260c36980f97eb /src/resolve/resolved-dns-packet.h | |
parent | ae8f0ec323f3cc1b75e2d25d4832fd9bc232261b (diff) | |
download | systemd-0354029bf572489bf968a39c537ec0cbdef828ce.tar.gz |
resolved: don't store udp/tcp fd in DnsPacket object
DnsPacket should better be a "dead" object, i.e. list facts, not track
resources. By including an fd in its fields it started tracking
resources however, without actually taking a ref to the fd (i.e. no
dup() or so was called on it).
Let's hence rework things so that we don#t have to keep track of the fd
a packet came in from. Instead, pass around the DnsStubListenerExtra
object wherever we need to.
This should be useful as soon as we start caching whole DnsPacket
objects to allow replying to DNSSEC/CO packets, i.e. where we have to
keep a copy of the original DnsPacket around for a long time in cache,
potentially much longer than the fds the packet was received on.
Diffstat (limited to 'src/resolve/resolved-dns-packet.h')
-rw-r--r-- | src/resolve/resolved-dns-packet.h | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/src/resolve/resolved-dns-packet.h b/src/resolve/resolved-dns-packet.h index 359cdcfd04..56614c4a07 100644 --- a/src/resolve/resolved-dns-packet.h +++ b/src/resolve/resolved-dns-packet.h @@ -66,7 +66,6 @@ struct DnsPacket { DnsResourceRecord *opt; /* Packet reception metadata */ - int fd; /* Used by UDP extra DNS stub listners */ int ifindex; int family, ipproto; union in_addr_union sender, destination; |