VirtualBox

Changeset 53510 in vbox


Ignore:
Timestamp:
Dec 11, 2014 2:14:21 PM (10 years ago)
Author:
vboxsync
Message:

NAT: sorecvfrom() - fix Windows assertion on the error leg introduced
in r95188. Ternary operator coerces both alternatives to the same
type, so -1 ends up converted to the wrong type. Rewrite using good
old "if".

File:
1 edited

Legend:

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

    r53399 r53510  
    879879                                 (struct sockaddr *)&addr, &addrlen,
    880880                                 NULL, NULL);
    881             nread = (status != SOCKET_ERROR) ? nbytes : -1;
     881            if (status != SOCKET_ERROR)
     882                nread = nbytes;
     883            else
     884                nread = -1;
    882885        }
    883886#endif
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