VirtualBox

Changeset 18226 in vbox


Ignore:
Timestamp:
Mar 24, 2009 7:57:30 PM (16 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
44951
Message:

get_dns_addr_domain: wcstombs can in theory return -1, so don't crash if it happens.

File:
1 edited

Legend:

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

    r18225 r18226  
    396396        }
    397397        buff_size = wcstombs(NULL, addr->DnsSuffix, 0);
    398         if (buff_size == 0)
     398        if (buff_size == 0 || buff_size == (size_t)-1)
    399399            goto next;
    400400        suffix = RTMemAllocZ(buff_size + 1);
Note: See TracChangeset for help on using the changeset viewer.

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