Changeset a3041a4 for examples


Ignore:
Timestamp:
01/10/12 14:15:58 (9 years ago)
Author:
Shane Alcock <salcock@…>
Branches:
4.0.1-hotfixes, cachetimestamps, develop, dpdk-ndag, etsilive, getfragoff, help, libtrace4, master, ndag_format, pfring, rc-4.0.1, rc-4.0.2, rc-4.0.3, rc-4.0.4, ringdecrementfix, ringperformance, ringtimestampfixes
Children:
8753bb8
Parents:
a0ec6f1
Message:
  • Fixed "unused but set" warnings that new gcc now likes to report
File:
1 edited

Legend:

Unmodified
Added
Removed
  • examples/tutorial/headerdemo.c

    rd025ff7 ra3041a4  
    219219        uint32_t remaining;
    220220        uint32_t prev_rem;
    221         libtrace_ip_t *ip;
    222221        libtrace_ip6_t *ip6;
    223222
     
    243242                case 0x0800:    /* IPv4 */
    244243                        /* Skip past the IPv4 header */
    245                         ip = (libtrace_ip_t *)ip_hdr;
    246244                        nexthdr = trace_get_payload_from_ip(ip_hdr, &protocol,
    247245                                        &remaining);
     
    332330        }
    333331
     332        /* If we don't have any post-transport payload, just return the
     333         * transport header size */
     334        if (!nexthdr)
     335                return trans_size;
     336       
    334337        /* Determine how many bytes we just skipped over and add it to the
    335338         * total transport size */
Note: See TracChangeset for help on using the changeset viewer.