Back to index

glibc  2.9
ether.h
Go to the documentation of this file.
00001 #ifndef _NETINET_ETHER_H
00002 #include <inet/netinet/ether.h>
00003 
00004 libc_hidden_proto (ether_aton_r)
00005 libc_hidden_proto (ether_ntoa_r)
00006 
00007 /* Because the `ethers' lookup does not fit so well in the scheme we
00008    define a dummy struct here which helps us to use the available
00009    functions.  */
00010 struct etherent
00011 {
00012   const char *e_name;
00013   struct ether_addr e_addr;
00014 };
00015 
00016 struct parser_data;
00017 extern int _nss_files_parse_etherent (char *line, struct etherent *result,
00018                                   struct parser_data *data,
00019                                   size_t datalen, int *errnop);
00020 libnss_files_hidden_proto (_nss_files_parse_etherent)
00021 
00022 #define DECLARE_NSS_PROTOTYPES(service)                                     \
00023 extern enum nss_status _nss_ ## service ## _setetherent (int __stayopen);     \
00024 extern enum nss_status _nss_ ## service ## _endetherent (void);                    \
00025 extern enum nss_status _nss_ ## service ## _getetherent_r                   \
00026                        (struct etherent *result, char *buffer,              \
00027                      size_t buflen, int *errnop);                           \
00028 extern enum nss_status _nss_ ## service ## _gethostton_r                    \
00029                        (const char *name, struct etherent *eth,                    \
00030                      char *buffer, size_t buflen, int *errnop);             \
00031 extern enum nss_status _nss_ ## service ## _getntohost_r                    \
00032                        (const struct ether_addr *addr,                      \
00033                      struct etherent *eth,                                  \
00034                      char *buffer, size_t buflen, int *errnop);
00035 
00036 DECLARE_NSS_PROTOTYPES (files)
00037 DECLARE_NSS_PROTOTYPES (nis)
00038 DECLARE_NSS_PROTOTYPES (nisplus)
00039 
00040 #undef DECLARE_NSS_PROTOTYPES
00041 
00042 #endif