summaryrefslogtreecommitdiff
path: root/services/outside_network.c
diff options
context:
space:
mode:
Diffstat (limited to 'services/outside_network.c')
-rw-r--r--services/outside_network.c15
1 files changed, 4 insertions, 11 deletions
diff --git a/services/outside_network.c b/services/outside_network.c
index 11951adea7bc..e87aba893d98 100644
--- a/services/outside_network.c
+++ b/services/outside_network.c
@@ -1870,17 +1870,10 @@ randomize_and_send_udp(struct pending* pend, sldns_buffer* packet, int timeout)
log_assert(pend->pc && pend->pc->cp);
/* send it over the commlink */
- if(outnet->udp_connect) {
- if(!comm_point_send_udp_msg(pend->pc->cp, packet, NULL, 0)) {
- portcomm_loweruse(outnet, pend->pc);
- return 0;
- }
- } else {
- if(!comm_point_send_udp_msg(pend->pc->cp, packet,
- (struct sockaddr*)&pend->addr, pend->addrlen)) {
- portcomm_loweruse(outnet, pend->pc);
- return 0;
- }
+ if(!comm_point_send_udp_msg(pend->pc->cp, packet,
+ (struct sockaddr*)&pend->addr, pend->addrlen, outnet->udp_connect)) {
+ portcomm_loweruse(outnet, pend->pc);
+ return 0;
}
/* system calls to set timeout after sending UDP to make roundtrip