aboutsummaryrefslogtreecommitdiff
path: root/networking/libiproute/ll_types.c
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2007-01-30 00:44:41 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2007-01-30 00:44:41 +0000
commit27a131e08e97acc2371421ddab9cf9372acffbb3 (patch)
tree499676f36c1bd490eceb1c127d670f1c2c4f3051 /networking/libiproute/ll_types.c
parenteb10e17b7bfdfe68a2357589ca11956386b0925d (diff)
downloadbusybox-27a131e08e97acc2371421ddab9cf9372acffbb3.tar.gz
preparatory patch for -Wwrite-strings #8 (missed part)
Diffstat (limited to 'networking/libiproute/ll_types.c')
-rw-r--r--networking/libiproute/ll_types.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/networking/libiproute/ll_types.c b/networking/libiproute/ll_types.c
index a53c89432..416ea6bbe 100644
--- a/networking/libiproute/ll_types.c
+++ b/networking/libiproute/ll_types.c
@@ -11,17 +11,16 @@
*/
#include <stdio.h>
#include <arpa/inet.h>
-
#include <linux/if_arp.h>
#include "rt_names.h"
-const 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 {
+static const struct {
int type;
- char *name;
+ const char *name;
} arphrd_names[] = {
{ 0, "generic" },
__PF(ETHER,ether)
@@ -109,7 +108,7 @@ __PF(VOID,void)
#undef __PF
int i;
- for (i=0; i<sizeof(arphrd_names)/sizeof(arphrd_names[0]); i++) {
+ for (i = 0; i < sizeof(arphrd_names)/sizeof(arphrd_names[0]); i++) {
if (arphrd_names[i].type == type)
return arphrd_names[i].name;
}