summaryrefslogtreecommitdiff
path: root/src/resolve/resolved-dns-transaction.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2015-08-25 18:51:21 +0200
committerLennart Poettering <lennart@poettering.net>2015-08-25 18:51:23 +0200
commit4667e00a61c2f60922558bc5e33ac9d3073a482c (patch)
treec7b9c08c08c7abc34bf03857ffd07a2f4b193509 /src/resolve/resolved-dns-transaction.c
parent498fb56739a5d18cb85d2ba3523759b1d141d770 (diff)
resolved: rename DNS UDP socket to 'dns_udp_fd'
This hopefully makes this a bit more expressive and clarifies that the fd is not used for the DNS TCP socket. This also mimics how the LLMNR UDP fd is named in the manager object.
Diffstat (limited to 'src/resolve/resolved-dns-transaction.c')
-rw-r--r--src/resolve/resolved-dns-transaction.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/resolve/resolved-dns-transaction.c b/src/resolve/resolved-dns-transaction.c
index 7b84c1bab8..8092bb514d 100644
--- a/src/resolve/resolved-dns-transaction.c
+++ b/src/resolve/resolved-dns-transaction.c
@@ -39,8 +39,8 @@ DnsTransaction* dns_transaction_free(DnsTransaction *t) {
dns_packet_unref(t->received);
dns_answer_unref(t->cached);
- sd_event_source_unref(t->dns_event_source);
- safe_close(t->dns_fd);
+ sd_event_source_unref(t->dns_udp_event_source);
+ safe_close(t->dns_udp_fd);
dns_server_unref(t->server);
dns_stream_free(t->stream);
@@ -98,7 +98,7 @@ int dns_transaction_new(DnsTransaction **ret, DnsScope *s, DnsResourceKey *key)
if (!t)
return -ENOMEM;
- t->dns_fd = -1;
+ t->dns_udp_fd = -1;
t->key = dns_resource_key_ref(key);
/* Find a fresh, unused transaction id */
@@ -328,8 +328,8 @@ static void dns_transaction_next_dns_server(DnsTransaction *t) {
assert(t);
t->server = dns_server_unref(t->server);
- t->dns_event_source = sd_event_source_unref(t->dns_event_source);
- t->dns_fd = safe_close(t->dns_fd);
+ t->dns_udp_event_source = sd_event_source_unref(t->dns_udp_event_source);
+ t->dns_udp_fd = safe_close(t->dns_udp_fd);
dns_scope_next_dns_server(t->scope);
}
@@ -500,16 +500,16 @@ static int dns_transaction_emit(DnsTransaction *t) {
if (fd < 0)
return fd;
- r = sd_event_add_io(t->scope->manager->event, &t->dns_event_source, fd, EPOLLIN, on_dns_packet, t);
+ r = sd_event_add_io(t->scope->manager->event, &t->dns_udp_event_source, fd, EPOLLIN, on_dns_packet, t);
if (r < 0)
return r;
- t->dns_fd = fd;
+ t->dns_udp_fd = fd;
fd = -1;
t->server = dns_server_ref(server);
}
- r = dns_scope_emit(t->scope, t->dns_fd, t->sent);
+ r = dns_scope_emit(t->scope, t->dns_udp_fd, t->sent);
if (r < 0)
return r;