VirtualBox

Changeset 16757 in vbox for trunk/src/VBox


Ignore:
Timestamp:
Feb 14, 2009 4:29:20 AM (16 years ago)
Author:
vboxsync
Message:

NAT: better logging in poll error handling

File:
1 edited

Legend:

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

    r16756 r16757  
    11131113                int inq, outq;
    11141114                int status;
    1115 #ifndef RT_OS_SOLARIS
    11161115                inq = -1;
    11171116                socklen_t optlen = sizeof(int);
    11181117                status = getsockopt(so->s, SOL_SOCKET, SO_ERROR, &err, &optlen);
    1119                 AssertRelease(status == 0 );
     1118                if (status != 0)
     1119                    LogRel(("NAT:can't get error status from %R[natsock]\n", so));
     1120#ifndef RT_OS_SOLARIS
    11201121                status = ioctl(so->s, FIONREAD, &inq); /* tcp(7) recommends SIOCINQ which is Linux specific */
    1121                 AssertRelease(status == 0 || status == EINVAL);/* EINVAL returned if socket in listen state tcp(7)*/
     1122                if (status != 0 || status != EINVAL)
     1123                {
     1124                    /* EINVAL returned if socket in listen state tcp(7)*/
     1125                    LogRel(("NAT:can't get depth of IN queue status from %R[natsock]\n", so));
     1126                }
    11221127                status = ioctl(so->s, TIOCOUTQ, &outq); /* SIOCOUTQ see previous comment */
    1123                 AssertRelease(status == 0);
     1128                if (status != 0)
     1129                    LogRel(("NAT:can't get depth of OUT queue from %R[natsock]\n", so));
    11241130#else
    11251131                inq = outq = -1;
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