Changeset 3504


Ignore:
Timestamp:
11/25/07 21:07:09 (6 years ago)
Author:
mickey
Message:

gsmd: start with gsmd_msg_auxdata union
Using a union here (similar to gsmd_evt_auxdata) allows for compiler checks and
is much less prone to fail than using pointer arithmetics.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/target/gsm/include/gsmd/usock.h

    r3449 r3504  
    584584} __attribute__((packed)); 
    585585 
     586struct gsmd_msg_auxdata { 
     587    union { 
     588        struct { 
     589            struct gsmd_signal_quality sigq; 
     590        } signal; 
     591        struct { 
     592            char name[16]; 
     593        } current_operator; 
     594        /* add more here please */ 
     595    } u; 
     596    u_int8_t data[0]; 
     597} __attribute__ ((packed)); 
     598 
    586599#ifdef __GSMD__ 
    587600 
Note: See TracChangeset for help on using the changeset viewer.