VirtualBox

Changeset 48438 in vbox for trunk/src/VBox/NetworkServices


Ignore:
Timestamp:
Sep 11, 2013 5:11:45 PM (11 years ago)
Author:
vboxsync
Message:

Check for PXREMAP_FAILED now that it can actually happen.

Location:
trunk/src/VBox/NetworkServices/NAT
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/NetworkServices/NAT/fwudp.c

    r48001 r48438  
    274274    struct pbuf *p;
    275275    ssize_t nread;
     276    int status;
    276277    err_t error;
    277278
     
    309310
    310311
    311     fwany_ipX_addr_set_src(&dgram->src_addr, (struct sockaddr *)&ss);
     312    status = fwany_ipX_addr_set_src(&dgram->src_addr, (struct sockaddr *)&ss);
     313    if (status == PXREMAP_FAILED) {
     314        return POLLIN;
     315    }
     316
    312317    if (ss.ss_family == AF_INET) {
    313318        const struct sockaddr_in *peer4 = (const struct sockaddr_in *)&ss;
  • trunk/src/VBox/NetworkServices/NAT/pxtcp.c

    r48238 r48438  
    12211221    LWIP_ASSERT1(ss.ss_family == fwspec->sdom);
    12221222
    1223     fwany_ipX_addr_set_src(&src_addr, (const struct sockaddr *)&ss);
     1223    status = fwany_ipX_addr_set_src(&src_addr, (const struct sockaddr *)&ss);
     1224    if (status == PXREMAP_FAILED) {
     1225        goto reset;
     1226    }
     1227
    12241228    if (ss.ss_family == PF_INET) {
    12251229        const struct sockaddr_in *peer4 = (const struct sockaddr_in *)&ss;
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