summaryrefslogtreecommitdiff
path: root/lib/plist.h
diff options
context:
space:
mode:
authorpaul <paul>2005-05-06 21:25:49 +0000
committerpaul <paul>2005-05-06 21:25:49 +0000
commit8cc4198f9fabe5f10f5a773de1503d82f33a01fb (patch)
tree77045da709ff66629bd12029b9ee17700360909b /lib/plist.h
parente7fe8c88c3d552400e1ae3ae9243319ab95d6f2d (diff)
2005-05-06 Paul Jakma <paul@dishone.st>
* (general) extern and static'ification of functions in code and header. Cleanup any definitions with unspecified arguments. Add casts for callback assignments where the callback is defined, typically, as passing void *, but the function being assigned has some other pointer type defined as its argument, as gcc complains about casts from void * to X* via function arguments. Fix some old K&R style function argument definitions. Add noreturn gcc attribute to some functions, as appropriate. Add unused gcc attribute to some functions (eg ones meant to help while debugging) Add guard defines to headers which were missing them. * command.c: (install_node) add const qualifier, still doesnt shut up the warning though, because of the double pointer. (cmp_node) ditto * keychain.c: (key_str2time) Add GET_LONG_RANGE() macro, derived fromn vty.h ones to fix some of the (long) < 0 warnings. * thread.c: (various) use thread_empty (cpu_record_hash_key) should cast to uintptr_t, a stdint.h type * vty.h: Add VTY_GET_IPV4_ADDRESS and VTY_GET_IPV4_PREFIX so they removed from ospfd/ospf_vty.h * zebra.h: Move definition of ZEBRA_PORT to here, to remove dependence of lib on zebra/zserv.h
Diffstat (limited to 'lib/plist.h')
-rw-r--r--lib/plist.h29
1 files changed, 17 insertions, 12 deletions
diff --git a/lib/plist.h b/lib/plist.h
index 01ac9874..fb3168a6 100644
--- a/lib/plist.h
+++ b/lib/plist.h
@@ -20,6 +20,9 @@
* Boston, MA 02111-1307, USA.
*/
+#ifndef _QUAGGA_PLIST_H
+#define _QUAGGA_PLIST_H
+
#define AFI_ORF_PREFIX 65535
enum prefix_list_type
@@ -62,17 +65,19 @@ struct orf_prefix
};
/* Prototypes. */
-void prefix_list_init (void);
-void prefix_list_reset (void);
-void prefix_list_add_hook (void (*func) (struct prefix_list *));
-void prefix_list_delete_hook (void (*func) (struct prefix_list *));
+extern void prefix_list_init (void);
+extern void prefix_list_reset (void);
+extern void prefix_list_add_hook (void (*func) (struct prefix_list *));
+extern void prefix_list_delete_hook (void (*func) (struct prefix_list *));
+
+extern struct prefix_list *prefix_list_lookup (afi_t, const char *);
+extern enum prefix_list_type prefix_list_apply (struct prefix_list *, void *);
-struct prefix_list *prefix_list_lookup (afi_t, const char *);
-enum prefix_list_type prefix_list_apply (struct prefix_list *, void *);
+extern struct stream * prefix_bgp_orf_entry (struct stream *,
+ struct prefix_list *,
+ u_char, u_char, u_char);
+extern int prefix_bgp_orf_set (char *, afi_t, struct orf_prefix *, int, int);
+extern void prefix_bgp_orf_remove_all (char *);
+extern int prefix_bgp_show_prefix_list (struct vty *, afi_t, char *);
-struct stream *
-prefix_bgp_orf_entry (struct stream *, struct prefix_list *,
- u_char, u_char, u_char);
-int prefix_bgp_orf_set (char *, afi_t, struct orf_prefix *, int, int);
-void prefix_bgp_orf_remove_all (char *);
-int prefix_bgp_show_prefix_list (struct vty *, afi_t, char *);
+#endif /* _QUAGGA_PLIST_H */