VirtualBox

Changeset 57651 in vbox for trunk


Ignore:
Timestamp:
Sep 8, 2015 2:45:56 AM (9 years ago)
Author:
vboxsync
Message:

NAT/Net: Fix a race on OS X and Windows (HAVE_TCP_POLLHUP == POLLIN).
r94443 broke assumption in pxtcp_pcb_sent() that pxtcp for which we
pull input is no longer registered with poll manager. It can still
beregistered for POLLOUT on these platforms.

File:
1 edited

Legend:

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

    r56300 r57651  
    22912291                          __func__, pxtcp->sock, sockerr));
    22922292
     2293#if HAVE_TCP_POLLHUP == POLLIN /* see counterpart in pxtcp_pmgr_pump() */
    22932294                /*
    2294                  * Since we are pulling, pxtcp is no longer registered
    2295                  * with poll manager so we can kill it directly.
     2295                 * It may still be registered with poll manager for POLLOUT.
     2296                 */
     2297                pxtcp_chan_send_weak(POLLMGR_CHAN_PXTCP_RESET, pxtcp);
     2298                return ERR_OK;
     2299#else
     2300                /*
     2301                 * It is no longer registered with poll manager so we
     2302                 * can kill it directly.
    22962303                 */
    22972304                pxtcp_pcb_reset_pxtcp(pxtcp);
    22982305                return ERR_ABRT;
     2306#endif
    22992307            }
    23002308        }
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