]> git.meshlink.io Git - catta/commitdiff
set IPv4 source address correctly on Windows
authorSven M. Hallberg <pesco@khjk.org>
Mon, 8 Sep 2014 19:03:48 +0000 (21:03 +0200)
committerSven M. Hallberg <pesco@khjk.org>
Mon, 8 Sep 2014 19:03:48 +0000 (21:03 +0200)
src/socket.c

index 28132db16de3bc113e219892a0339ad4acdc45ec..7e893a0e041b03a557c05deae8316251f0be9729 100644 (file)
@@ -544,6 +544,9 @@ int catta_send_dns_packet_ipv4(
 #ifdef HAVE_IPI_SPEC_DST
         if (src_address)
             pkti->ipi_spec_dst.s_addr = src_address->address;
+#else
+        if (src_address)
+            pkti->ipi_addr.s_addr = src_address->address;
 #endif
     }
 #elif defined(IP_MULTICAST_IF)