aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCelelibi <celelibi@gmail.com>2013-11-10 08:46:03 -0500
committerGene Cumm <gene.cumm@gmail.com>2014-01-29 11:55:14 -0500
commit232fa3ed2e1aa8317906e820c638c2c91558a825 (patch)
treeb0dfb010a207d5b5716c26ff3e0bdbe2f8f551c9
parent73c4268bd1399273b295f899087cef6aabf0721d (diff)
downloadsyslinux-232fa3ed2e1aa8317906e820c638c2c91558a825.tar.gz
syslinux-232fa3ed2e1aa8317906e820c638c2c91558a825.tar.xz
syslinux-232fa3ed2e1aa8317906e820c638c2c91558a825.zip
efi/udp.c: Use existing UDP port in core_udp_sendto()
core_udp_open() obtained a port allocation. Continue using it. Author: Celelibi <celelibi@gmail.com> Signed-off-by: Gene Cumm <gene.cumm@gmail.com>
-rw-r--r--efi/udp.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/efi/udp.c b/efi/udp.c
index 8169025a..b1cae6f7 100644
--- a/efi/udp.c
+++ b/efi/udp.c
@@ -333,6 +333,9 @@ void core_udp_sendto(struct pxe_pvt_inode *socket, const void *data,
memset(&udata, 0, sizeof(udata));
+ /* Re-use the existing local port number */
+ udata.StationPort = socket->net.efi.localport;
+
memcpy(&udata.StationAddress, &IPInfo.myip, sizeof(IPInfo.myip));
memcpy(&udata.SubnetMask, &IPInfo.netmask, sizeof(IPInfo.netmask));
memcpy(&udata.RemoteAddress, &ip, sizeof(ip));