Patch from Bernhard Fischer to make a bunch of symbols static
which were otherwise cluttering the global namespace.
This commit is contained in:
@@ -48,7 +48,7 @@ static struct
|
||||
struct rtnl_handle *rth;
|
||||
} filter;
|
||||
|
||||
void print_link_flags(FILE *fp, unsigned flags, unsigned mdown)
|
||||
static void print_link_flags(FILE *fp, unsigned flags, unsigned mdown)
|
||||
{
|
||||
fprintf(fp, "<");
|
||||
flags &= ~IFF_RUNNING;
|
||||
|
||||
@@ -361,7 +361,7 @@ static int do_add(int cmd, int argc, char **argv)
|
||||
return -1;
|
||||
}
|
||||
|
||||
int do_del(int argc, char **argv)
|
||||
static int do_del(int argc, char **argv)
|
||||
{
|
||||
struct ip_tunnel_parm p;
|
||||
|
||||
@@ -381,7 +381,7 @@ int do_del(int argc, char **argv)
|
||||
return -1;
|
||||
}
|
||||
|
||||
void print_tunnel(struct ip_tunnel_parm *p)
|
||||
static void print_tunnel(struct ip_tunnel_parm *p)
|
||||
{
|
||||
char s1[256];
|
||||
char s2[256];
|
||||
|
||||
@@ -90,7 +90,7 @@ __PF(ECONET,econet)
|
||||
#undef __PF
|
||||
|
||||
|
||||
char * ll_proto_n2a(unsigned short id, char *buf, int len)
|
||||
const char * ll_proto_n2a(unsigned short id, char *buf, int len)
|
||||
{
|
||||
int i;
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
|
||||
#include <linux/if_arp.h>
|
||||
|
||||
char * ll_type_n2a(int type, char *buf, int len)
|
||||
const char * ll_type_n2a(int type, char *buf, int len)
|
||||
{
|
||||
#define __PF(f,n) { ARPHRD_##f, #n },
|
||||
static struct {
|
||||
|
||||
@@ -76,7 +76,7 @@ static void rtnl_rtprot_initialize(void)
|
||||
rtnl_rtprot_tab, 256);
|
||||
}
|
||||
|
||||
char * rtnl_rtprot_n2a(int id, char *buf, int len)
|
||||
const char * rtnl_rtprot_n2a(int id, char *buf, int len)
|
||||
{
|
||||
if (id<0 || id>=256) {
|
||||
snprintf(buf, len, "%d", id);
|
||||
@@ -143,7 +143,7 @@ static void rtnl_rtscope_initialize(void)
|
||||
rtnl_rtscope_tab, 256);
|
||||
}
|
||||
|
||||
char * rtnl_rtscope_n2a(int id, char *buf, int len)
|
||||
const char * rtnl_rtscope_n2a(int id, char *buf, int len)
|
||||
{
|
||||
if (id<0 || id>=256) {
|
||||
snprintf(buf, len, "%d", id);
|
||||
@@ -206,7 +206,7 @@ static void rtnl_rtrealm_initialize(void)
|
||||
rtnl_rtrealm_tab, 256);
|
||||
}
|
||||
|
||||
char * rtnl_rtrealm_n2a(int id, char *buf, int len)
|
||||
const char * rtnl_rtrealm_n2a(int id, char *buf, int len)
|
||||
{
|
||||
if (id<0 || id>=256) {
|
||||
snprintf(buf, len, "%d", id);
|
||||
@@ -272,7 +272,7 @@ static void rtnl_rttable_initialize(void)
|
||||
rtnl_rttable_tab, 256);
|
||||
}
|
||||
|
||||
char * rtnl_rttable_n2a(int id, char *buf, int len)
|
||||
const char * rtnl_rttable_n2a(int id, char *buf, int len)
|
||||
{
|
||||
if (id<0 || id>=256) {
|
||||
snprintf(buf, len, "%d", id);
|
||||
@@ -334,7 +334,7 @@ static void rtnl_rtdsfield_initialize(void)
|
||||
rtnl_rtdsfield_tab, 256);
|
||||
}
|
||||
|
||||
char * rtnl_dsfield_n2a(int id, char *buf, int len)
|
||||
const char * rtnl_dsfield_n2a(int id, char *buf, int len)
|
||||
{
|
||||
if (id<0 || id>=256) {
|
||||
snprintf(buf, len, "%d", id);
|
||||
|
||||
Reference in New Issue
Block a user