summaryrefslogtreecommitdiff
path: root/slirp/udp.c
diff options
context:
space:
mode:
authorbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2005-06-05 17:11:42 +0000
committerbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>2005-06-05 17:11:42 +0000
commit101c59356292c30ed5c8f7138c7680b4dc3d4811 (patch)
tree9804bca016979ade791f1ca9eb4191779acf58d5 /slirp/udp.c
parentb685369795f028535862cb3caddaf219c655db2a (diff)
downloadqemu-101c59356292c30ed5c8f7138c7680b4dc3d4811.tar.gz
qemu-101c59356292c30ed5c8f7138c7680b4dc3d4811.tar.bz2
qemu-101c59356292c30ed5c8f7138c7680b4dc3d4811.zip
64 bit fixes (initial patch by Gwenole Beauchesne)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1458 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'slirp/udp.c')
-rw-r--r--slirp/udp.c18
1 files changed, 12 insertions, 6 deletions
diff --git a/slirp/udp.c b/slirp/udp.c
index aefa0b749b..079c543534 100644
--- a/slirp/udp.c
+++ b/slirp/udp.c
@@ -420,10 +420,16 @@ struct talk_request {
#endif
struct cu_header {
- char dest[8];
- short family;
- u_short port;
- u_long addr;
+ uint16_t d_family; // destination family
+ uint16_t d_port; // destination port
+ uint32_t d_addr; // destination address
+ uint16_t s_family; // source family
+ uint16_t s_port; // source port
+ uint32_t s_addr; // source address
+ uint32_t seqn; // sequence number
+ uint16_t message; // message
+ uint16_t data_type; // data type
+ uint16_t pkt_len; // packet length
} *cu_head;
switch(so->so_emu) {
@@ -610,8 +616,8 @@ struct cu_header {
if (getsockname(so->s, (struct sockaddr *)&addr, &addrlen) < 0)
return;
cu_head = mtod(m, struct cu_header *);
- cu_head->port = addr.sin_port;
- cu_head->addr = (u_long) our_addr.s_addr;
+ cu_head->s_port = addr.sin_port;
+ cu_head->s_addr = our_addr.s_addr;
}
return;