forked from Mirror/frr
Quagga: Fixup some compile warnings
Fixup compile warnings for when you turn on --enable-gcc-ultra-verbose=yes Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
This commit is contained in:
parent
3a7c85d1de
commit
35dece848d
|
@ -192,7 +192,7 @@ sighup (void)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* SIGINT handler. */
|
/* SIGINT handler. */
|
||||||
void
|
__attribute__((__noreturn__)) void
|
||||||
sigint (void)
|
sigint (void)
|
||||||
{
|
{
|
||||||
zlog_notice ("Terminating on signal");
|
zlog_notice ("Terminating on signal");
|
||||||
|
@ -218,7 +218,7 @@ sigusr1 (void)
|
||||||
Zebra route removal and protocol teardown are not meant to be done here.
|
Zebra route removal and protocol teardown are not meant to be done here.
|
||||||
For example, "retain_mode" may be set.
|
For example, "retain_mode" may be set.
|
||||||
*/
|
*/
|
||||||
static void
|
static __attribute__((__noreturn__)) void
|
||||||
bgp_exit (int status)
|
bgp_exit (int status)
|
||||||
{
|
{
|
||||||
struct bgp *bgp;
|
struct bgp *bgp;
|
||||||
|
|
|
@ -164,7 +164,7 @@ reload ()
|
||||||
safe_strerror (errno));
|
safe_strerror (errno));
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static __attribute__((__noreturn__)) void
|
||||||
terminate (int i)
|
terminate (int i)
|
||||||
{
|
{
|
||||||
exit (i);
|
exit (i);
|
||||||
|
@ -183,14 +183,14 @@ sighup (void)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
__attribute__((__noreturn__)) void
|
||||||
sigint (void)
|
sigint (void)
|
||||||
{
|
{
|
||||||
zlog_notice ("Terminating on signal SIGINT");
|
zlog_notice ("Terminating on signal SIGINT");
|
||||||
terminate (0);
|
terminate (0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
__attribute__((__noreturn__)) void
|
||||||
sigterm (void)
|
sigterm (void)
|
||||||
{
|
{
|
||||||
zlog_notice ("Terminating on signal SIGTERM");
|
zlog_notice ("Terminating on signal SIGTERM");
|
||||||
|
|
|
@ -20,7 +20,7 @@ double randg01(void);
|
||||||
long nrand(long);
|
long nrand(long);
|
||||||
void free_arc(void *);
|
void free_arc(void *);
|
||||||
|
|
||||||
unsigned long timer ()
|
unsigned long timer (void)
|
||||||
{ struct tms hold;
|
{ struct tms hold;
|
||||||
|
|
||||||
times(&hold);
|
times(&hold);
|
||||||
|
@ -88,7 +88,7 @@ long init_seed;
|
||||||
#define B 2147483647
|
#define B 2147483647
|
||||||
#define BF 2147483647.
|
#define BF 2147483647.
|
||||||
|
|
||||||
static long irand ()
|
static long irand (void)
|
||||||
|
|
||||||
{ internal_seed = ( internal_seed * A ) & B;
|
{ internal_seed = ( internal_seed * A ) & B;
|
||||||
return (long) internal_seed ;
|
return (long) internal_seed ;
|
||||||
|
@ -107,7 +107,7 @@ static long irand ()
|
||||||
#define A1 37252
|
#define A1 37252
|
||||||
#define A2 29589
|
#define A2 29589
|
||||||
|
|
||||||
static long xrand()
|
static long xrand(void)
|
||||||
|
|
||||||
{ unsigned long is1, is2;
|
{ unsigned long is1, is2;
|
||||||
|
|
||||||
|
@ -122,7 +122,7 @@ static long xrand()
|
||||||
/*********************************************************************/
|
/*********************************************************************/
|
||||||
|
|
||||||
|
|
||||||
double rand01()
|
double rand01(void)
|
||||||
|
|
||||||
{ return (double) (irand() / BF) ;
|
{ return (double) (irand() / BF) ;
|
||||||
}
|
}
|
||||||
|
@ -131,7 +131,7 @@ double rand01()
|
||||||
|
|
||||||
#define NK 12
|
#define NK 12
|
||||||
|
|
||||||
double randg01()
|
double randg01(void)
|
||||||
|
|
||||||
{ int i;
|
{ int i;
|
||||||
double sum = 0;
|
double sum = 0;
|
||||||
|
|
|
@ -758,10 +758,10 @@ static int
|
||||||
in6addr_cmp (struct in6_addr *addr1, struct in6_addr *addr2)
|
in6addr_cmp (struct in6_addr *addr1, struct in6_addr *addr2)
|
||||||
{
|
{
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
u_char *p1, *p2;
|
const u_char *p1, *p2;
|
||||||
|
|
||||||
p1 = (u_char *)addr1;
|
p1 = (const u_char *)addr1;
|
||||||
p2 = (u_char *)addr2;
|
p2 = (const u_char *)addr2;
|
||||||
|
|
||||||
for (i = 0; i < sizeof (struct in6_addr); i++)
|
for (i = 0; i < sizeof (struct in6_addr); i++)
|
||||||
{
|
{
|
||||||
|
|
|
@ -250,7 +250,7 @@ nsm_change_callback (struct in_addr ifaddr, struct in_addr nbraddr,
|
||||||
* ---------------------------------------------------------
|
* ---------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
|
||||||
static int usage()
|
static int usage(void)
|
||||||
{
|
{
|
||||||
printf("Usage: ospfclient <ospfd> <lsatype> <opaquetype> <opaqueid> <ifaddr> <areaid>\n");
|
printf("Usage: ospfclient <ospfd> <lsatype> <opaquetype> <opaqueid> <ifaddr> <areaid>\n");
|
||||||
printf("where ospfd : router where API-enabled OSPF daemon is running\n");
|
printf("where ospfd : router where API-enabled OSPF daemon is running\n");
|
||||||
|
|
|
@ -50,7 +50,7 @@ Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
||||||
|
|
||||||
static unsigned int spf_reason_flags = 0;
|
static unsigned int spf_reason_flags = 0;
|
||||||
|
|
||||||
static void ospf_clear_spf_reason_flags ()
|
static void ospf_clear_spf_reason_flags (void )
|
||||||
{
|
{
|
||||||
spf_reason_flags = 0;
|
spf_reason_flags = 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -65,7 +65,7 @@ strcmp_safe (const char *s1, const char *s2)
|
||||||
}
|
}
|
||||||
|
|
||||||
static struct ripng_offset_list *
|
static struct ripng_offset_list *
|
||||||
ripng_offset_list_new ()
|
ripng_offset_list_new (void)
|
||||||
{
|
{
|
||||||
struct ripng_offset_list *new;
|
struct ripng_offset_list *new;
|
||||||
|
|
||||||
|
|
|
@ -32,7 +32,7 @@
|
||||||
#include "ripngd/ripng_route.h"
|
#include "ripngd/ripng_route.h"
|
||||||
|
|
||||||
static struct ripng_aggregate *
|
static struct ripng_aggregate *
|
||||||
ripng_aggregate_new ()
|
ripng_aggregate_new (void)
|
||||||
{
|
{
|
||||||
struct ripng_aggregate *new;
|
struct ripng_aggregate *new;
|
||||||
|
|
||||||
|
|
|
@ -76,7 +76,7 @@ line_del (char *line)
|
||||||
}
|
}
|
||||||
|
|
||||||
struct config *
|
struct config *
|
||||||
config_new ()
|
config_new (void)
|
||||||
{
|
{
|
||||||
struct config *config;
|
struct config *config;
|
||||||
config = XCALLOC (MTYPE_VTYSH_CONFIG, sizeof (struct config));
|
config = XCALLOC (MTYPE_VTYSH_CONFIG, sizeof (struct config));
|
||||||
|
|
|
@ -116,7 +116,7 @@ struct vtysh_user
|
||||||
struct list *userlist;
|
struct list *userlist;
|
||||||
|
|
||||||
struct vtysh_user *
|
struct vtysh_user *
|
||||||
user_new ()
|
user_new (void)
|
||||||
{
|
{
|
||||||
return XCALLOC (0, sizeof (struct vtysh_user));
|
return XCALLOC (0, sizeof (struct vtysh_user));
|
||||||
}
|
}
|
||||||
|
|
|
@ -603,7 +603,7 @@ zfpm_connection_up (const char *detail)
|
||||||
* Check if an asynchronous connect() to the FPM is complete.
|
* Check if an asynchronous connect() to the FPM is complete.
|
||||||
*/
|
*/
|
||||||
static void
|
static void
|
||||||
zfpm_connect_check ()
|
zfpm_connect_check (void)
|
||||||
{
|
{
|
||||||
int status;
|
int status;
|
||||||
socklen_t slen;
|
socklen_t slen;
|
||||||
|
|
Loading…
Reference in a new issue