Changeset a2d8d59 in mainline for uspace/lib/net/include/icmp_header.h


Ignore:
Timestamp:
2011-01-17T16:26:10Z (13 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
7e36c8d
Parents:
f1938c6 (diff), ffaba00 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

merge ICMP rewrite

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/net/include/icmp_header.h

    rf1938c6 ra2d8d59  
    4545
    4646/** ICMP header size in bytes. */
    47 #define ICMP_HEADER_SIZE        sizeof(icmp_header_t)
    48 
    49 /** Type definition of the echo specific data.
    50  * @see icmp_echo
    51  */
    52 typedef struct icmp_echo icmp_echo_t;
     47#define ICMP_HEADER_SIZE  sizeof(icmp_header_t)
    5348
    5449/** Echo specific data. */
    55 struct icmp_echo {
     50typedef struct icmp_echo {
    5651        /** Message idintifier. */
    5752        icmp_param_t identifier;
    5853        /** Message sequence number. */
    5954        icmp_param_t sequence_number;
    60 } __attribute__ ((packed));
    61 
    62 /** Type definition of the internet control message header.
    63  * @see icmp_header
    64  */
    65 typedef struct icmp_header icmp_header_t;
     55} __attribute__((packed)) icmp_echo_t;
    6656
    6757/** Internet control message header. */
    68 struct icmp_header {
     58typedef struct icmp_header {
    6959        /** The type of the message. */
    7060        uint8_t type;
     
    8373         */
    8474        uint16_t checksum;
    85 
     75       
    8676        /** Message specific data. */
    8777        union {
    8878                /** Echo specific data. */
    89                 icmp_echo_t  echo;
     79                icmp_echo_t echo;
    9080                /** Proposed gateway value. */
    9181                in_addr_t gateway;
     
    10797                } param;
    10898        } un;
    109 } __attribute__ ((packed));
     99} __attribute__((packed)) icmp_header_t;
    110100
    111101#endif
Note: See TracChangeset for help on using the changeset viewer.