diff options
author | Natanael Copa <ncopa@alpinelinux.org> | 2011-10-07 11:13:27 +0200 |
---|---|---|
committer | Natanael Copa <ncopa@alpinelinux.org> | 2011-10-07 11:13:27 +0200 |
commit | f8b192af8b6611c3832df3024cbabaafffb47591 (patch) | |
tree | 43eb3a2493224a4a9b3303fc69fa5355d1b432c3 /pingu_route.h | |
parent | 2aa0126a96f8fe44c8b6a61e4051bbf9c3b3dc79 (diff) | |
download | pingu-f8b192af8b6611c3832df3024cbabaafffb47591.tar.bz2 pingu-f8b192af8b6611c3832df3024cbabaafffb47591.tar.xz |
pingu: rename pingu_gateway to pingu_route
Diffstat (limited to 'pingu_route.h')
-rw-r--r-- | pingu_route.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/pingu_route.h b/pingu_route.h new file mode 100644 index 0000000..5badb10 --- /dev/null +++ b/pingu_route.h @@ -0,0 +1,30 @@ +#ifndef pingu_route_H +#define pingu_route_H + +#include "list.h" +#include "sockaddr_util.h" + +struct pingu_route { + union sockaddr_any gw_addr; + union sockaddr_any dest; + union sockaddr_any src; + unsigned char dst_len; + unsigned char src_len; + + int metric; + unsigned char protocol; + unsigned char scope; + unsigned char type; + struct list_head route_list_entry; +}; + +void pingu_route_del_all(struct list_head *head); +void pingu_route_add(struct list_head *route_list, + struct pingu_route *gw); +void pingu_route_del(struct list_head *route_list, + struct pingu_route *gw); +int is_default_gw(struct pingu_route *route); +struct pingu_route *pingu_route_first_default(struct list_head *route_list); + + +#endif |