VirtualBox

Ignore:
Timestamp:
Jan 7, 2009 7:51:29 PM (16 years ago)
Author:
vboxsync
Message:

warnings and minor fixes to coding style

Location:
trunk/src/VBox/Devices/Network/slirp
Files:
6 edited

Legend:

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

    r15407 r15845  
    319319    struct bootp_t *bp = mtod(m, struct bootp_t *);
    320320
    321     if (bp->bp_op == BOOTP_REQUEST) {
     321    if (bp->bp_op == BOOTP_REQUEST)
    322322        bootp_reply(pData, bp);
    323     }
    324 }
     323}
  • trunk/src/VBox/Devices/Network/slirp/ip_input.c

    r15792 r15845  
    526526            fpp = fp;
    527527            fp = TAILQ_NEXT(fp, ipq_list);
    528             if(--fpp->ipq_ttl == 0) {
     528            if(--fpp->ipq_ttl == 0)
     529            {
    529530                ipstat.ips_fragtimeout += fpp->ipq_nfrags;
    530531                ip_freef(pData, &ipq[i], fpp);
  • trunk/src/VBox/Devices/Network/slirp/tcp_input.c

    r15792 r15845  
    515515#if 0
    516516        if (ts_present && SEQ_LEQ(ti->ti_seq, tp->last_ack_sent) &&
    517                 SEQ_LT(tp->last_ack_sent, ti->ti_seq + ti->ti_len)) {
     517                SEQ_LT(tp->last_ack_sent, ti->ti_seq + ti->ti_len))
     518        {
    518519            tp->ts_recent_age = tcp_now;
    519520            tp->ts_recent = ts_val;
  • trunk/src/VBox/Devices/Network/slirp/tcp_timer.c

    r14964 r15845  
    279279                goto dropit;
    280280/*          if (tp->t_socket->so_options & SO_KEEPALIVE && */
    281             if ((so_options) && tp->t_state <= TCPS_CLOSE_WAIT) {
     281            if ((so_options) && tp->t_state <= TCPS_CLOSE_WAIT)
     282            {
    282283                if (tp->t_idle >= tcp_keepidle + tcp_maxidle)
    283284                    goto dropit;
  • trunk/src/VBox/Devices/Network/slirp/tftp.c

    r14964 r15845  
    305305    if (   !strncmp((const char*)spt->filename, "../", 3)
    306306        || (spt->filename[strlen((const char *)spt->filename) - 1] == '/')
    307         ||  strstr((const char *)spt->filename, "/../")) {
     307        ||  strstr((const char *)spt->filename, "/../"))
     308    {
    308309        tftp_send_error(pData, spt, 2, "Access violation", tp);
    309310        return;
  • trunk/src/VBox/Devices/Network/slirp/udp.c

    r15792 r15845  
    238238
    239239    ttl = ip->ip_ttl = save_ip.ip_ttl;
    240     ret = setsockopt(so->s, IPPROTO_IP, IP_TTL, &ttl, sizeof(ttl));
    241     if (ret < 0) {
    242         LogRel(("NAT: Error (%s) occurred while setting TTL(%d) attribute of IP packet to socket %R[natsock]\n", strerror(errno), ip->ip_ttl, so));
    243     }
     240    ret = setsockopt(so->s, IPPROTO_IP, IP_TTL, (const char*)&ttl, sizeof(ttl));
     241    if (ret < 0)
     242        LogRel(("NAT: Error (%s) occurred while setting TTL(%d) attribute "
     243                "of IP packet to socket %R[natsock]\n", strerror(errno), ip->ip_ttl, so));
    244244
    245245    if (sosendto(pData, so, m) == -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