[ipxe-devel] udp padding in udp_demux()

Michael Brown mcb30 at ipxe.org
Tue Sep 16 15:59:50 BST 2014


On 15/09/14 12:55, Wissam Shoukair wrote:
> What is the purpose of the padding in this function?
>
> static struct udp_connection * udp_demux ( struct sockaddr_tcpip *local ) {

udp_demux() is treating the socket address as a generic TCP/IP socket 
address (which doesn't know anything about the IPv4 or IPv6 network 
layers).  It checks the st_family and st_port fields (which it 
understands), and compares the rest of the address as an opaque blob.

Michael


More information about the ipxe-devel mailing list