tcpdump mailing list archives

Re: libpcap on linux issue


From: Darren Reed <darrenr () reed wattle id au>
Date: Thu, 13 Feb 2003 22:06:53 +1100 (EST)

In some email I received from Guy Harris, sie wrote:
On Wed, Feb 12, 2003 at 03:06:19AM -0800, Guy Harris wrote:
On Wed, Feb 12, 2003 at 02:39:35PM +1100, Darren Reed wrote:
Now on this particular linux system, none of the header files in the
/usr/include directory tree define SA_LEN

Not even <sys/socket.h>, which, in glibc 2.3 does

    /* Return the length of a `sockaddr' structure.  */
    #ifdef _HAVE_SA_LEN
    # define SA_LEN(_x)      (_x)->sa_len   
    #else
    extern int __libc_sa_len (sa_family_t __af);
    extern int __libc_sa_len_internal (sa_family_t __af) attribute_hidden;
    # ifndef NOT_IN_libc
    #  define SA_LEN(_x)      INTUSE(__libc_sa_len)((_x)->sa_family)
    # else
    #  define SA_LEN(_x)      __libc_sa_len((_x)->sa_family)
    # endif
    #endif

OK, what about "/usr/include/bits/sockaddr.h" or
"/usr/include/bits/socket.h"?  Does one of them define SA_LEN and, if
so, does that header eventually get included by <sys/socket.h>?

# find /usr/include -print | xargs grep SA_LEN
/usr/include/linux/atm.h:#define        ATM_ESA_LEN     20              /* ATM End System Address length */
/usr/include/linux/atm.h:        unsigned char  prv[ATM_ESA_LEN];/* private ATM address */
/usr/include/linux/atmlec.h:                        unsigned char atm_addr[ATM_ESA_LEN];
/usr/include/linux/atmlec.h:                        unsigned char atm_addr[ATM_ESA_LEN]; /* reqestor ATM addr */
/usr/include/linux/atmlec.h:        unsigned char atm_addr[ATM_ESA_LEN];
/usr/include/linux/atmmpc.h:        uint8_t   eg_MPC_ATM_addr[ATM_ESA_LEN];
/usr/include/linux/atmmpc.h:        uint8_t   in_MPC_data_ATM_addr[ATM_ESA_LEN];
/usr/include/linux/atmmpc.h:        uint8_t  MPS_ctrl[ATM_ESA_LEN];

Darren
-
This is the TCPDUMP workers list. It is archived at
http://www.tcpdump.org/lists/workers/index.html
To unsubscribe use mailto:tcpdump-workers-request () tcpdump org?body=unsubscribe


Current thread: