Browse Source

[udp] Add AF_INET6 socket opener

Signed-off-by: Michael Brown <mcb30@ipxe.org>
tags/v1.20.1
Michael Brown 11 years ago
parent
commit
e6ad90540b
1 changed files with 9 additions and 2 deletions
  1. 9
    2
      src/net/udp.c

+ 9
- 2
src/net/udp.c View File

395
  ***************************************************************************
395
  ***************************************************************************
396
  */
396
  */
397
 
397
 
398
-/** UDP socket opener */
399
-struct socket_opener udp_socket_opener __socket_opener = {
398
+/** UDP IPv4 socket opener */
399
+struct socket_opener udp_ipv4_socket_opener __socket_opener = {
400
 	.semantics	= UDP_SOCK_DGRAM,
400
 	.semantics	= UDP_SOCK_DGRAM,
401
 	.family		= AF_INET,
401
 	.family		= AF_INET,
402
 	.open		= udp_open,
402
 	.open		= udp_open,
403
 };
403
 };
404
 
404
 
405
+/** UDP IPv6 socket opener */
406
+struct socket_opener udp_ipv6_socket_opener __socket_opener = {
407
+	.semantics	= UDP_SOCK_DGRAM,
408
+	.family		= AF_INET6,
409
+	.open		= udp_open,
410
+};
411
+
405
 /** Linkage hack */
412
 /** Linkage hack */
406
 int udp_sock_dgram = UDP_SOCK_DGRAM;
413
 int udp_sock_dgram = UDP_SOCK_DGRAM;
407
 
414
 

Loading…
Cancel
Save