VirtualBox

Changeset 27443 in vbox for trunk/src/VBox/Devices/Network


Ignore:
Timestamp:
Mar 17, 2010 12:51:59 PM (15 years ago)
Author:
vboxsync
Message:

NAT: paranoid check of mbuf incrementation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/Network/slirp/socket.c

    r27441 r27443  
    10591059    if (RT_N2H_U16(ip->ip_len) < hlen + ICMP_MINLEN)
    10601060    {
    1061         Log(("send_icmp_to_guest: ICMP header is too small to understand which type/subtype of the datagram\n"));
     1061       Log(("send_icmp_to_guest: ICMP header is too small to understand which type/subtype of the datagram\n"));
    10621062       return;
    10631063    }
     
    11371137    else
    11381138    {
     1139        int size = m->m_size;
    11391140        m_inc(m, len); /*increase the room of the mbuf up to len*/
     1141        if (size == m->m_size)
     1142        {
     1143            Log(("send_icmp_to_guest: extending buffer was failed (packet is dropped)\n"));
     1144            return;
     1145        }
    11401146        memcpy(m->m_data + original_hlen, buff + hlen, len - hlen);
    11411147    }
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette