Ignore:
Timestamp:
04/02/08 16:32:01 (13 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:
dd1217b
Parents:
007fb43
Message:

Some fixes to deal with errors and warnings that appear with old gcc - e.g. 2.95

  • Added 'static' to functions that are only used internally
  • Moved variable declarations to the start of the code block, before any actual code
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libpacketdump/link_4.c

    r3996329 rf5d654e  
    9999} __attribute__ ((__packed__)) ieee80211_payload;
    100100
    101 char *macaddr(uint8_t mac[]) {
     101static char *macaddr(uint8_t mac[]) {
    102102        static char ether_buf[18] = {0, };
    103103        trace_ether_ntoa(mac, ether_buf);
     
    724724       
    725725        if (len > hdrlen) {
    726                 pld = (ieee80211_payload *) ((char *)pkt + hdrlen) ;
    727726                int payload_offset = 0;
    728727                uint16_t ethertype = 0;
     728                pld = (ieee80211_payload *) ((char *)pkt + hdrlen) ;
    729729                if (ntohs(pld->ethertype) == 0xaaaa) {
    730730                        /* 802.11 payload contains an 802.2 LLC/SNAP header */
Note: See TracChangeset for help on using the changeset viewer.