diff options
author | blueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162> | 2009-01-13 19:48:42 +0000 |
---|---|---|
committer | blueswir1 <blueswir1@c046a42c-6fe2-441c-8c8c-71466251a162> | 2009-01-13 19:48:42 +0000 |
commit | 429d0a3db8138ae6a545500b92dbe532629a24e1 (patch) | |
tree | 39a83db9110fec6aeb0b75db86f3073f41611ec6 /slirp/udp.c | |
parent | Make pci_nic_init() use qemu_setup_nic_model() (Mark McLoughlin) (diff) | |
download | qemu-kvm-429d0a3db8138ae6a545500b92dbe532629a24e1.tar.gz qemu-kvm-429d0a3db8138ae6a545500b92dbe532629a24e1.tar.bz2 qemu-kvm-429d0a3db8138ae6a545500b92dbe532629a24e1.zip |
Fix 64 bit issue in slirp
Signed-off-by: Gleb Natapov <gleb@redhat.com>
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6288 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'slirp/udp.c')
-rw-r--r-- | slirp/udp.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/slirp/udp.c b/slirp/udp.c index ca353b7ae..c9926181a 100644 --- a/slirp/udp.c +++ b/slirp/udp.c @@ -136,8 +136,7 @@ udp_input(m, iphlen) * Checksum extended UDP header and data. */ if (UDPCKSUM && uh->uh_sum) { - ((struct ipovly *)ip)->ih_next = 0; - ((struct ipovly *)ip)->ih_prev = 0; + memset(&((struct ipovly *)ip)->ih_mbuf, 0, sizeof(struct mbuf_ptr)); ((struct ipovly *)ip)->ih_x1 = 0; ((struct ipovly *)ip)->ih_len = uh->uh_ulen; /* keep uh_sum for ICMP reply @@ -283,7 +282,7 @@ int udp_output2(struct socket *so, struct mbuf *m, * and addresses and length put into network format. */ ui = mtod(m, struct udpiphdr *); - ui->ui_next = ui->ui_prev = 0; + memset(&ui->ui_i.ih_mbuf, 0 , sizeof(struct mbuf_ptr)); ui->ui_x1 = 0; ui->ui_pr = IPPROTO_UDP; ui->ui_len = htons(m->m_len - sizeof(struct ip)); /* + sizeof (struct udphdr)); */ |