forked from Mirror/frr
lib: random unused bits cleanup
Signed-off-by: David Lamparter <equinox@diac24.net>
This commit is contained in:
parent
25d8623340
commit
eb51bb9b1f
|
@ -114,12 +114,6 @@ char *buffer_getstr(struct buffer *b)
|
|||
return s;
|
||||
}
|
||||
|
||||
/* Return 1 if buffer is empty. */
|
||||
int buffer_empty(struct buffer *b)
|
||||
{
|
||||
return (b->head == NULL);
|
||||
}
|
||||
|
||||
/* Clear and free all allocated data. */
|
||||
void buffer_reset(struct buffer *b)
|
||||
{
|
||||
|
|
|
@ -2498,8 +2498,8 @@ DEFUN (no_ipv6_access_list_remark_comment,
|
|||
return no_ipv6_access_list_remark(self, vty, argc, argv);
|
||||
}
|
||||
|
||||
void config_write_access_zebra(struct vty *, struct filter *);
|
||||
void config_write_access_cisco(struct vty *, struct filter *);
|
||||
static void config_write_access_zebra(struct vty *, struct filter *);
|
||||
static void config_write_access_cisco(struct vty *, struct filter *);
|
||||
|
||||
/* show access-list command. */
|
||||
static int filter_show(struct vty *vty, const char *name, afi_t afi)
|
||||
|
@ -2685,7 +2685,7 @@ DEFUN (show_ipv6_access_list_name,
|
|||
return filter_show(vty, argv[idx_word]->arg, AFI_IP6);
|
||||
}
|
||||
|
||||
void config_write_access_cisco(struct vty *vty, struct filter *mfilter)
|
||||
static void config_write_access_cisco(struct vty *vty, struct filter *mfilter)
|
||||
{
|
||||
struct filter_cisco *filter;
|
||||
|
||||
|
@ -2724,7 +2724,7 @@ void config_write_access_cisco(struct vty *vty, struct filter *mfilter)
|
|||
}
|
||||
}
|
||||
|
||||
void config_write_access_zebra(struct vty *vty, struct filter *mfilter)
|
||||
static void config_write_access_zebra(struct vty *vty, struct filter *mfilter)
|
||||
{
|
||||
struct filter_zebra *filter;
|
||||
struct prefix *p;
|
||||
|
|
|
@ -38,9 +38,9 @@ DEFINE_MTYPE_STATIC(LIB, CMD_TOKENS, "Command desc")
|
|||
|
||||
/** headers **/
|
||||
void grammar_sandbox_init(void);
|
||||
void pretty_print_graph(struct vty *vty, struct graph_node *, int, int,
|
||||
static void pretty_print_graph(struct vty *vty, struct graph_node *, int, int,
|
||||
struct graph_node **, size_t);
|
||||
void init_cmdgraph(struct vty *, struct graph **);
|
||||
static void init_cmdgraph(struct vty *, struct graph **);
|
||||
|
||||
/** shim interface commands **/
|
||||
static struct graph *nodegraph = NULL, *nodegraph_free = NULL;
|
||||
|
@ -491,8 +491,9 @@ void grammar_sandbox_init(void)
|
|||
* @param start the node to take as the root
|
||||
* @param level indent level for recursive calls, always pass 0
|
||||
*/
|
||||
void pretty_print_graph(struct vty *vty, struct graph_node *start, int level,
|
||||
int desc, struct graph_node **stack, size_t stackpos)
|
||||
static void pretty_print_graph(struct vty *vty, struct graph_node *start,
|
||||
int level, int desc, struct graph_node **stack,
|
||||
size_t stackpos)
|
||||
{
|
||||
// print this node
|
||||
char tokennum[32];
|
||||
|
@ -550,7 +551,7 @@ void pretty_print_graph(struct vty *vty, struct graph_node *start, int level,
|
|||
}
|
||||
|
||||
/** stuff that should go in command.c + command.h */
|
||||
void init_cmdgraph(struct vty *vty, struct graph **graph)
|
||||
static void init_cmdgraph(struct vty *vty, struct graph **graph)
|
||||
{
|
||||
// initialize graph, add start noe
|
||||
*graph = graph_new();
|
||||
|
|
|
@ -121,21 +121,6 @@ int setsockopt_ipv6_pktinfo(int sock, int val)
|
|||
return ret;
|
||||
}
|
||||
|
||||
/* Set multicast hops val to the socket. */
|
||||
int setsockopt_ipv6_checksum(int sock, int val)
|
||||
{
|
||||
int ret;
|
||||
|
||||
#ifdef GNU_LINUX
|
||||
ret = setsockopt(sock, IPPROTO_RAW, IPV6_CHECKSUM, &val, sizeof(val));
|
||||
#else
|
||||
ret = setsockopt(sock, IPPROTO_IPV6, IPV6_CHECKSUM, &val, sizeof(val));
|
||||
#endif /* GNU_LINUX */
|
||||
if (ret < 0)
|
||||
flog_err(EC_LIB_SOCKET, "can't setsockopt IPV6_CHECKSUM");
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* Set multicast hops val to the socket. */
|
||||
int setsockopt_ipv6_multicast_hops(int sock, int val)
|
||||
{
|
||||
|
|
|
@ -33,7 +33,6 @@ extern int getsockopt_so_sendbuf(const int sock);
|
|||
extern int getsockopt_so_recvbuf(const int sock);
|
||||
|
||||
extern int setsockopt_ipv6_pktinfo(int, int);
|
||||
extern int setsockopt_ipv6_checksum(int, int);
|
||||
extern int setsockopt_ipv6_multicast_hops(int, int);
|
||||
extern int setsockopt_ipv6_unicast_hops(int, int);
|
||||
extern int setsockopt_ipv6_hoplimit(int, int);
|
||||
|
|
|
@ -32,7 +32,7 @@
|
|||
* Wrapper this silliness if we
|
||||
* don't have systemd
|
||||
*/
|
||||
void systemd_send_information(const char *info)
|
||||
static void systemd_send_information(const char *info)
|
||||
{
|
||||
#if defined HAVE_SYSTEMD
|
||||
sd_notify(0, info);
|
||||
|
|
|
@ -32,7 +32,6 @@ extern "C" {
|
|||
* To turn on systemd compilation, use --enable-systemd on
|
||||
* configure run.
|
||||
*/
|
||||
void systemd_send_information(const char *info);
|
||||
void systemd_send_stopping(void);
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in a new issue